//^ requires template.ContainingBlock != containingBlock; //^ ensures this.containingBlock == containingBlock; /// <summary> /// A copy constructor that allocates an instance that is the same as the given template, except for its containing block. /// </summary> /// <param name="containingBlock">A new value for containing block. This replaces template.ContainingBlock in the resulting copy of template.</param> /// <param name="template">The template to copy.</param> protected VccCompileTimeConstantWhoseSignDependsOnAnotherExpression(BlockStatement containingBlock, VccCompileTimeConstantWhoseSignDependsOnAnotherExpression template) : base(containingBlock, template) { this.compileTimeConstant = (CompileTimeConstant)template.compileTimeConstant.MakeCopyFor(containingBlock); this.expression = template.expression.MakeCopyFor(containingBlock); }
//^^ requires this.Value != null; public override CompileTimeConstant GetAsConstant() { CompileTimeConstant result = new VccCompileTimeConstantWhoseSignDependsOnAnotherExpression(base.GetAsConstant(), this.RightOperand); result.SetContainingExpression(this); return result; }