# type

作者: MasterFocus 最近更新时间: 20100617

A group of functions to check, retrieve and compare AHK variable types.

type_common( p_InputList )
type_is( p_Input , p_Type )
type_same( p_Input1 , p_Input2 )
type_same02( p_Input1 , p_Input2 )
type_var( p_Input )

关于函数的参数和返回值, 请参阅其源码.

#### 备注

Added prefix "type_" to all function names (and changed slightly), to make it stdlib conform.
This library lacks an external documentation, but every function is detailed described in the souce.
Visit MasterFocus webpage:
o http://www.autohotkey.net/~MasterFocus/AHK/

关于此函数(集)的更新细节和注意事项, 请参见 AutoHotkey 论坛: http://www.autohotkey.com/forum/viewtopic.php?t=59341

#### 许可

此函数(集)是基于 GNU LGPL 许可的开源项目. 想了解许可详情, 请参见 lgpl-3.0.txt

#### 示例

    ; #Include type.ahk
    #NoEnv
    SendMode Input
    SetWorkingDir %A_ScriptDir%

    ; Example by MasterFocus, copied from source and adjusted to match renamed functions.
    text := "* EXAMPLES *"
    text .= "`n"
    text .= "`nvar1 = " ( var1 := "AB4D" ) ": " type_var( var1 )
    text .= "`nvar2 = " ( var2 := "8df3K" ) ": " type_var( var2 )
    text .= "`nvar3 = " ( var3 := "2345" ) ": " type_var( var3 )
    text .= "`n"
    text .= "`n" "SameTypes(var1,var2): " type_same(var1,var2)
    text .= "`n" "SameTypes02(var1,var3): " type_same(var1,var3)
    text .= "`n"
    text .= "`n" "CommonTypes(""var1,var2,var3""): " type_common("var1,var2,var3")
    text .= "`n" "CommonTypes(""var3,var1,var2""): " type_common("var3,var1,var2")

    MsgBox %text%