示例#1
0
        public override BoundNode VisitSizeOfOperator(BoundSizeOfOperator node)
        {
            if (_inExpressionLambda && node.ConstantValue == null)
            {
                Error(ErrorCode.ERR_ExpressionTreeContainsPointerOp, node);
            }

            return(base.VisitSizeOfOperator(node));
        }
        public override BoundNode VisitSizeOfOperator(BoundSizeOfOperator node)
        {
            if (_inExpressionLambda && node.ConstantValue == null)
            {
                Error(ErrorCode.ERR_ExpressionTreeContainsPointerOp, node);
            }

            return base.VisitSizeOfOperator(node);
        }
 private static BoundExpression VisitSizeOfOperator(BoundSizeOfOperator node)
 {
     // error should have been reported earlier
     // Diagnostics.Add(ErrorCode.ERR_ExpressionTreeContainsPointerOp, node.Syntax.Location);
     return new BoundBadExpression(node.Syntax, default(LookupResultKind), ImmutableArray<Symbol>.Empty, ImmutableArray.Create<BoundNode>(node), node.Type);
 }
 private static BoundExpression VisitSizeOfOperator(BoundSizeOfOperator node)
 {
     // error should have been reported earlier
     // Diagnostics.Add(ErrorCode.ERR_ExpressionTreeContainsPointerOp, node.Syntax.Location);
     return(new BoundBadExpression(node.Syntax, default(LookupResultKind), ImmutableArray <Symbol> .Empty, ImmutableArray.Create <BoundExpression>(node), node.Type));
 }