public VariableReferenceExpression(VariableDeclarationStatement declaration)
 {
     if (declaration==null)
         throw new ArgumentNullException("declaration");
     this.declaration = declaration;
 }
示例#2
0
文件: Expr.cs 项目: spib/nhcontrib
        /// <summary>
        /// Creates a reference to a given variable
        /// </summary>
        /// <param name="p">
        /// The <see cref="VariableDeclarationStatement"/> instance to reference.
        /// </param>
        /// <returns>
        /// A <see cref="VariableReferenceExpression"/> instance referencing
        /// <paramref name="v"/>.
        /// </returns>
        /// <exception cref="ArgumentNullException">
        /// <paramref name="v"/> is a null reference (Noting in Visual Basic)
        /// </exception>
        public static VariableReferenceExpression Var(
			VariableDeclarationStatement v)
        {
            if (v==null)
                throw new ArgumentNullException("v");
            return new VariableReferenceExpression(v);
        }