将黑客语言支持函数重载多态性?
Will Hack language support function-overloading polymorphism?
函数重载:如何保持相同的定义(体)和改变参数?
Function overloading: how to keep the same definition (body) and only change the parameters?
这一特定的构造函数重载使调用方可以指定是否允许自动转换。
This particular constructor overload enables the caller to specify whether auto-converting is allowed.
函数重载允许一个函数名定义多个函数,函数重载使程序设计简单化。
Function overloading permits one function-name to define multiple functions. Function overloading enables program-design simple.
函数重载确定的第三步是确定与函数调用中使用的实际参数匹配最佳的可行函数。
The third step of function overload resolution determines which viable function has the best match for the actual arguments in the call.
函数重载确定,即函数匹配是将函数调用与重载函数集合中的一个函数相关联的过程。
Function overload resolution (also known as function matching) is the process by which a function call is associated with a specific function from a set of overloaded functions.
函数重载和运算符重载的两种松软的东西——有许多面向对象的语言不支持这2种特征。
Function overloading and operator overloading are two such fluffy things - there are many OO languages that don't support those 2 features.
要理解函数重载,必须理解如何定义一组重载函数和编译器如何决定对某一调用使用哪个函数。
To understand function overloading, we must understand how to define a set of overloaded functions and how the compiler decides which function to use for a given call.
当设计环境创建一个组件或控件的实例时,它不会尝试为使用参数的构造函数重载提供任何参数。
When the design environment creates an instance of your component or control, it does not attempt to provide any parameters to constructor overloads that take parameters.
函数和方法的默认参数极大地减少了需要创建的重载方法数量。
Default arguments on functions and methods greatly reduce the number of overloaded methods you need to create.
不支持探测重载和多态的函数。
Probing of overloaded and polymorphic functions is not supported.
在编写扩展函数时,应谨慎处理根据实参类型进行的方法重载。
Be cautious about method overloading based on argument type when you write extension functions.
最后,调用使用char类型的参数的重载函数func。
Finally, it calls the overloaded function func with char type arguments.
你可以在名为Initialize的重载函数中编写代码,从而在载入你的包时与VisualStudio交互。
The override function named Initialize is where you can put code to interact with Visual Studio when your package is loaded.
一般情况下,没有必要重载成员函数GetSite 。
Usually there's no need to override the GetSite member function.
构造函数方法使用标准化的方法来确保重载值中不包含XML解析器所使用的符号。
The constructor method uses the normalize method to ensure that the override value strings do not contain symbols used by XML parser.
因此请总是确认你已经为你的类型重载了以上函数,不要以任何方式依赖于缺省实现。
Therefore always make sure that you overload the functions for your types and do not rely on the defaults in any way.
具有同一名字的成员函数和非成员函数不会相互重载。
Member and nonmember functions with the same name do not overload one another.
但为了解释作用域与重载的相互作用,我们将违反上述规则而使用局部函数声明。
To explain how scope interacts with overloading we will violate this practice and use a local function declaration.
不像我开始描述的两个定时器类,System . Threading . Timer有四个重载构造函数,就像下面这样。
Unlike the previous two timer classes that I have just covered, System.Threading.Timer has four overloaded constructors. The following shows what they look like.
出现在相同作用域中的两个函数,如果具有相同的名字而形参表不同,则称为重载函数。
Two functions that appear in the same scope are overloaded if they have the same name but have different parameter lists.
通过自动提取函数调用中实际使用的实参与重载集合中各个函数提供的形参做比较,编译器实现该调用与函数的匹配。
The compiler matches a call to a function automatically by comparing the actual arguments used in the call with the parameters offered by each function in the overload set.
重载集合中的函数通常有不同个数的参数或无关联的参数类型。
Often the functions in the overload set differ in terms of the number of arguments, or the types of the arguments are unrelated.
重载集合中的函数通常有不同个数的参数或无关联的参数类型。
Often the functions in the overload set differ in terms of the number of arguments, or the types of the arguments are unrelated.
应用推荐