type-checking:类型检查;在编译或运行时,验证程序中表达式、变量、函数参数与返回值等是否符合语言的类型规则,以发现类型不匹配等错误。(也常写作 type checking)
/ˈtaɪp ˌtʃekɪŋ/
The compiler performs type-checking before it builds the program.
编译器会在构建程序之前进行类型检查。
Strong type-checking helps prevent subtle bugs, especially when a large codebase is maintained by many developers.
强类型检查有助于避免隐蔽的漏洞,尤其是在多人维护的大型代码库中。
由 type(类型)+ checking(检查)构成的复合词。type 源自希腊语 typos(印记、模子、范型),经拉丁语与法语进入英语;check 可能来自古法语 eschequier(核对、检查),与“核算/对账”的动作相关。合起来即“检查类型是否符合规则”。