src/share/classes/com/sun/tools/javac/code/Symbol.java
Print this page
@@ -43,11 +43,11 @@
import static com.sun.tools.javac.code.Flags.*;
import static com.sun.tools.javac.code.Kinds.*;
import static com.sun.tools.javac.code.TypeTag.CLASS;
import static com.sun.tools.javac.code.TypeTag.FORALL;
import static com.sun.tools.javac.code.TypeTag.TYPEVAR;
-import com.sun.tools.javac.tree.JCTree.JCVariableDecl;
+import com.sun.tools.javac.tree.JCTree.*;
/** Root class for Java symbols. It contains subclasses
* for specific sorts of symbols, such as variables, methods and operators,
* types, packages. Each subclass is represented as a static inner class
* inside Symbol.
@@ -204,10 +204,16 @@
if (metadata != null || a.nonEmpty()) {
initedMetadata().setDeclarationAttributes(a);
}
}
+ public void appendDeclarationAttributes(List<Attribute.Compound> a) {
+ if (metadata != null || a.nonEmpty()) {
+ initedMetadata().append(a);
+ }
+ }
+
public void setTypeAttributes(List<Attribute.TypeCompound> a) {
if (metadata != null || a.nonEmpty()) {
if (metadata == null)
metadata = new SymbolMetadata(this);
metadata.setTypeAttributes(a);
@@ -1250,15 +1256,19 @@
return Constants.decode(getConstValue(), type);
}
public void setLazyConstValue(final Env<AttrContext> env,
final Attr attr,
- final JCVariableDecl variable)
+ final JCVariableDecl variable,
+ final JCLambda currentLambda,
+ final boolean speculative)
{
setData(new Callable<Object>() {
public Object call() {
- return attr.attribLazyConstantValue(env, variable, type);
+ return attr.attribLazyConstantValue(env, variable, type,
+ currentLambda,
+ speculative);
}
});
}
/**