Quotations.Var 构造函数 (F#)

新建一个具有给定名称、类型和可变性的变量。

命名空间/模块路径: Microsoft.FSharp.Quotations

程序集:FSharp.Core(在 FSharp.Core.dll 中)

// Signature:
new Var : string * Type * ?bool -> Var

// Usage:
new Var (name, typ)
new Var (name, typ, isMutable = isMutable)

参数

  • name
    类型:string

    声明的变量名称。

  • typ
    类型:Type

    与变量关联的类型。

  • isMutable
    类型:bool

    指示该变量是否表示一个可变的存储位置。 默认值为 false。

返回值

创建的变量。

平台

Windows 7、Windows Vista SP2、Windows XP SP3、Windows XP x64 SP2、Windows Server 2008 R2、Windows Server 2008 SP2、Windows Server 2003 SP2

版本信息

F# 运行时

受以下版本支持:2.0、4.0

Silverlight

受以下版本支持:3

请参见

参考

Quotations.Var 类 (F#)

Microsoft.FSharp.Quotations 命名空间 (F#)