public Declaration(CompilationSourceUnit /*!*/ sourceUnit, IDeclaree /*!*/ declaree, bool isPartial, bool isConditional, Scope scope, Text.Span position) { this.sourceUnit = sourceUnit; this.declaree = declaree; this.scope = scope; this.span = position; this.isPartial = isPartial; this.isConditional = isConditional; }
/// <summary> /// Used by compiler. /// </summary> public GlobalConstant(QualifiedName qualifiedName, PhpMemberAttributes memberAttributes, CompilationSourceUnit /*!*/ sourceUnit, bool isConditional, Scope scope, Text.Span position) : base(new DConstantDesc(sourceUnit.CompilationUnit.Module, memberAttributes, null)) { Debug.Assert(sourceUnit != null); this.qualifiedName = qualifiedName; this.declaration = new Declaration(sourceUnit, this, false, isConditional, scope, position); //this.origin = origin; if (sourceUnit.CompilationUnit is ScriptCompilationUnit) // J: place the constant into <script> type so it can be reflected properly { scriptTypeBuilder = ((ScriptCompilationUnit)sourceUnit.CompilationUnit).ScriptBuilder.ScriptTypeBuilder; } }