use of org.eclipse.ceylon.model.typechecker.model.Scope in project ceylon by eclipse.
the class DeclarationVisitor method visit.
@Override
public void visit(Tree.NamedArgumentList that) {
NamedArgumentList nal = new NamedArgumentList();
nal.setId(id++);
for (Tree.NamedArgument na : that.getNamedArguments()) {
Tree.Identifier id = na.getIdentifier();
if (id != null) {
nal.getArgumentNames().add(id.getText());
}
}
that.setNamedArgumentList(nal);
visitElement(that, nal);
Scope o = enterScope(nal);
super.visit(that);
exitScope(o);
}
use of org.eclipse.ceylon.model.typechecker.model.Scope in project ceylon by eclipse.
the class DeclarationVisitor method enterScope.
private Scope enterScope(Scope innerScope) {
Scope outerScope = scope;
scope = innerScope;
return outerScope;
}
use of org.eclipse.ceylon.model.typechecker.model.Scope in project ceylon by eclipse.
the class DeclarationVisitor method visit.
@Override
public void visit(Tree.SpecifierStatement that) {
Tree.Term lhs = that.getBaseMemberExpression();
if (lhs instanceof Tree.ParameterizedExpression) {
Tree.ParameterizedExpression pe = (Tree.ParameterizedExpression) lhs;
pe.setLeftTerm(true);
}
Specification s = new Specification();
s.setId(id++);
visitElement(that, s);
Scope o = enterScope(s);
super.visit(that);
exitScope(o);
}
use of org.eclipse.ceylon.model.typechecker.model.Scope in project ceylon by eclipse.
the class DeclarationVisitor method visit.
@Override
public void visit(Tree.AnyInterface that) {
Interface i = that.getDeclarationModel();
that.setDeclarationModel(i);
visitDeclaration(that, i);
Scope o = enterScope(i);
super.visit(that);
exitScope(o);
}
use of org.eclipse.ceylon.model.typechecker.model.Scope in project ceylon by eclipse.
the class DeclarationVisitor method visit.
@Override
public void visit(Tree.ImportMemberOrTypeList that) {
ImportList il = new ImportList();
unit.getImportLists().add(il);
that.setImportList(il);
il.setContainer(scope);
il.setUnit(unit);
Scope o = enterScope(il);
super.visit(that);
exitScope(o);
}
Aggregations