I noticed that i can set a return type on a function to ‘Void’ aswell as ‘void’ and just wondered if there was and benefit of either?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Void(with uppercase “v”) was ActionScript 2 version of ActionScript 3void.AS3 docs (void):
Specifies that a function cannot return any value. The void type is a special type that contains exactly one value: undefined. It is special in that its use is limited to the return type of a function. You cannot use void as a type annotation for a property.
http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/specialTypes.html#void
AS2 docs (Void):
The Void data type has one value, void, and is used in a function definition to indicate that the function does not return a value, as shown in the following example:
http://help.adobe.com/en_US/AS2LCR/Flash_10.0/help.html?content=00000037.html