Search in sources :

Example 1 with AnnotationList

use of com.redhat.ceylon.compiler.typechecker.tree.Tree.AnnotationList in project ceylon-compiler by ceylon.

the class ClassTransformer method makeShortcutRefinementAnnotationTrees.

private AnnotationList makeShortcutRefinementAnnotationTrees() {
    AnnotationList annotationList = new AnnotationList(null);
    Tree.Annotation shared = new Tree.Annotation(null);
    Tree.BaseMemberExpression sharedPrimary = new Tree.BaseMemberExpression(null);
    sharedPrimary.setDeclaration(typeFact().getLanguageModuleDeclaration("shared"));
    shared.setPrimary(sharedPrimary);
    annotationList.addAnnotation(shared);
    Tree.Annotation actual = new Tree.Annotation(null);
    Tree.BaseMemberExpression actualPrimary = new Tree.BaseMemberExpression(null);
    actualPrimary.setDeclaration(typeFact().getLanguageModuleDeclaration("actual"));
    actual.setPrimary(actualPrimary);
    annotationList.addAnnotation(actual);
    return annotationList;
}
Also used : BaseMemberExpression(com.redhat.ceylon.compiler.typechecker.tree.Tree.BaseMemberExpression) JCPrimitiveTypeTree(com.sun.tools.javac.tree.JCTree.JCPrimitiveTypeTree) JCTree(com.sun.tools.javac.tree.JCTree) Tree(com.redhat.ceylon.compiler.typechecker.tree.Tree) BaseMemberExpression(com.redhat.ceylon.compiler.typechecker.tree.Tree.BaseMemberExpression) AnnotationList(com.redhat.ceylon.compiler.typechecker.tree.Tree.AnnotationList) JCAnnotation(com.sun.tools.javac.tree.JCTree.JCAnnotation)

Aggregations

Tree (com.redhat.ceylon.compiler.typechecker.tree.Tree)1 AnnotationList (com.redhat.ceylon.compiler.typechecker.tree.Tree.AnnotationList)1 BaseMemberExpression (com.redhat.ceylon.compiler.typechecker.tree.Tree.BaseMemberExpression)1 JCTree (com.sun.tools.javac.tree.JCTree)1 JCAnnotation (com.sun.tools.javac.tree.JCTree.JCAnnotation)1 JCPrimitiveTypeTree (com.sun.tools.javac.tree.JCTree.JCPrimitiveTypeTree)1