Exemplo n.º 1
0
        public SingletonDefinition(LexicalScope/*!*/ definedScope, Expression/*!*/ singleton, Body/*!*/ body, SourceSpan location)
            : base(definedScope, body, location)
        {
            ContractUtils.RequiresNotNull(singleton, "singleton");

            _singleton = singleton;
        }
Exemplo n.º 2
0
        public ClassDefinition(LexicalScope/*!*/ definedScope, ConstantVariable/*!*/ name, Expression superClass, Body/*!*/ body, SourceSpan location)
            : base(definedScope, name, body, location)
        {
            ContractUtils.RequiresNotNull(name, "name");

            _superClass = superClass;
        }
Exemplo n.º 3
0
        public ModuleDefinition(LexicalScope/*!*/ definedScope, ConstantVariable/*!*/ qualifiedName, Body/*!*/ body, SourceSpan location)
            : base(definedScope, body, location)
        {
            ContractUtils.RequiresNotNull(qualifiedName, "qualifiedName");

            _qualifiedName = qualifiedName;
        }
Exemplo n.º 4
0
        protected DefinitionExpression(LexicalScope/*!*/ definedScope, Body/*!*/ body, SourceSpan location) 
            : base(location) {
            ContractUtils.RequiresNotNull(definedScope, "definedScope");
            ContractUtils.RequiresNotNull(body, "body");

            _definedScope = definedScope;
            _body = body;
        }
Exemplo n.º 5
0
        public MethodDefinition(LexicalScope/*!*/ definedScope, Expression target, string/*!*/ name, Parameters parameters, Body/*!*/ body, 
            SourceSpan location)
            : base(definedScope, body, location) {
            Assert.NotNull(name);

            _target = target;
            _name = name;
            _parameters = parameters ?? Parameters.Empty;
        }
Exemplo n.º 6
0
        public MethodDefinition(LexicalScope/*!*/ definedScope, Expression target, string/*!*/ name, Parameters parameters, Body/*!*/ body, 
            SourceSpan location)
            : base(definedScope, body, location)
        {
            Assert.NotNull(name);

            // only for-loop block might use other than local variable for unsplat:
            Debug.Assert(parameters.Unsplat == null || parameters.Unsplat is LocalVariable);

            _target = target;
            _name = name;
            _parameters = parameters ?? Parameters.Empty;
        }
Exemplo n.º 7
0
 protected ModuleDefinition(LexicalScope/*!*/ definedScope, Body/*!*/ body, SourceSpan location)
     : base(definedScope, body, location) {
     _qualifiedName = null;
 }
Exemplo n.º 8
0
 public virtual void Exit(Body/*!*/ node) { }
Exemplo n.º 9
0
 public virtual bool Enter(Body/*!*/ node) { return true; }
Exemplo n.º 10
0
        public ClassDefinition(LexicalScope /*!*/ definedScope, ConstantVariable /*!*/ name, Expression superClass, Body /*!*/ body, SourceSpan location)
            : base(definedScope, name, body, location)
        {
            ContractUtils.RequiresNotNull(name, "name");

            _superClass = superClass;
        }
Exemplo n.º 11
0
 public virtual void Exit(Body /*!*/ node)
 {
 }
Exemplo n.º 12
0
 public virtual bool Enter(Body /*!*/ node)
 {
     return(true);
 }