FaridAgl Posted August 8, 2013 Posted August 8, 2013 Shouldn't it return an error? MsgBox(0, "", Test) Func Test() Return "Test" EndFunc http://faridaghili.ir
Developers Jos Posted August 8, 2013 Developers Posted August 8, 2013 Are you using current production or beta? SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
FaridAgl Posted August 8, 2013 Author Posted August 8, 2013 Latest beta of AutoIt, with latest beta of AutoIt wrapper etc (scite, tidy, obfuscator, ...). It gives an error with 3.3.8.1, but no error with 3.3.9.15, shows an empty MsgBox and runs normaly. http://faridaghili.ir
Administrators Jon Posted August 9, 2013 Administrators Posted August 9, 2013 As expected. Test is evaluating to the pointer of the function Test, which is blank when tried to display as a string.
trancexx Posted August 9, 2013 Posted August 9, 2013 (edited) The pointer isn't explicit so it more correct to use term "reference" not to cause confusion. Edited August 9, 2013 by trancexx ♡♡♡ . eMyvnE
FaridAgl Posted August 9, 2013 Author Posted August 9, 2013 So, do you mean it's just OK? http://faridaghili.ir
James Posted August 9, 2013 Posted August 9, 2013 So, do you mean it's just OK? Yes, a ptr/reference doesn't have a string value. Blog - Seriously epic web hosting - Twitter - GitHub - Cachet HQ
wraithdu Posted August 9, 2013 Posted August 9, 2013 Shouldn't it return an error? Maybe this will help. MsgBox(0, "", VarGetType(Test)) Func Test() Return "Test" EndFunc
jaberwacky Posted August 9, 2013 Posted August 9, 2013 Oh cool, I thought I read that you had done away with that feature! MsgBox(0, "", Test(AnotherTest)) Func AnotherTest() Return "HELLO WORLD" EndFunc Func Test($myFunc) Return $myFunc() EndFunc Awesome. Helpful Posts and Websites: AutoIt Wiki | Can't find what you're looking for on the Forum? My scripts: Guiscape | Baroque AU3 Code Formatter | MouseHoverCalltips | SciTe Customization GUI | ActiveWindowTrack Toy | Monitor Configuration UDF
James Posted August 9, 2013 Posted August 9, 2013 Oh cool, I thought I read that you had done away with that feature! MsgBox(0, "", Test(AnotherTest)) Func AnotherTest() Return "HELLO WORLD" EndFunc Func Test($myFunc) Return $myFunc() EndFunc Awesome. Functions are first class citizens in the latest betas. It's what allows this awesomeness to occur. Blog - Seriously epic web hosting - Twitter - GitHub - Cachet HQ
jaberwacky Posted August 9, 2013 Posted August 9, 2013 Yup. I don't know where I got the idea that they were removed from. Must have been something that I got mixed up in the stirring pot that is my brain. Helpful Posts and Websites: AutoIt Wiki | Can't find what you're looking for on the Forum? My scripts: Guiscape | Baroque AU3 Code Formatter | MouseHoverCalltips | SciTe Customization GUI | ActiveWindowTrack Toy | Monitor Configuration UDF
Administrators Jon Posted August 9, 2013 Administrators Posted August 9, 2013 The basic part is still there (functions referenced in vars).
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now