c.haslam Posted September 23, 2018 Posted September 23, 2018 (edited) This snippet passed a #AutoIt3Wrapper_Au3Check_Parameters=-d -w 1 -w 2 -w 3 -w- 4 -w 5 -w 6 -w 7 check but failed at run time: Local $sResult = _cFileSelectFolder( _ 'test', _ ; $title 'Desktop', _ ; $sTopItemText _ ; 'My Documents', _ ; $sTopItemText '', _ ; $sInitPath $iWid, _ $iHt, _ $iLeft, _ $iTop, _ $hGui, _ ; $hParent $sExclFolders, _ $bHideHidden, _ $bHideSystem) Edited September 23, 2018 by c.haslam Spoiler CDebug Dumps values of variables including arrays and DLL structs, to a GUI, to the Console, and to the Clipboard
c.haslam Posted September 23, 2018 Author Posted September 23, 2018 (edited) Post 1 continued: Message from AutoIt was: >Running:(3.3.14.5):F:\Program Files\AutoIt3\autoit3.exe "F:\AutoIt scripts\cFileSelectFolder\caller.au3" --> Press Ctrl+Alt+Break to Restart or Ctrl+Break to Stop "F:\AutoIt scripts\cFileSelectFolder\caller.au3" (26) : ==> Error parsing function call.: Local $sResult = _cFileSelectFolder( 'test', 'Desktop', _ Local $sResult = _cFileSelectFolder( 'test', 'Desktop', ^ ERROR ->15:00:31 AutoIt3.exe ended.rc:1 +>15:00:31 AutoIt3Wrapper Finished. >Exit code: 1 Time: 4.972 It appears to me that Au3Check is correct in accepting my code. You may wonder: why would I want to code like this? I have the arguments to the function on multiple lines so I can readily identify each. In debugging, I wish to change one of the arguments temporarily. It is true that I can work around what looks to be like a deficiency in the parser. It appears that one can't have a line with only the continuation character (preceded by a space), and followed by an in-line comment I do not understand why it takes the parser to pickup on this "error".. To me, if it is an error and not a deficiency in the parser, it should be picked up by AU3Check. Put another way: it would be nice if the parser allowed the code above. Thoughts? Edited September 23, 2018 by c.haslam Spoiler CDebug Dumps values of variables including arrays and DLL structs, to a GUI, to the Console, and to the Clipboard
Developers Jos Posted September 23, 2018 Developers Posted September 23, 2018 5 minutes ago, c.haslam said: Thoughts? Please post something that is runable so we can have a look. Jos 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.
FrancescoDiMuro Posted September 23, 2018 Posted September 23, 2018 (edited) @c.haslam You can't have those lines in that way... That's how you can do it: ; This will give you "Error parsing function call." ; Local $intBit = BitOR(_ ; 1, _ ; 0) ; This will not Local $intBit = BitOR(1, _ 0 _ ; Or 0) ) ConsoleWrite($intBit & @CRLF) Edited September 23, 2018 by FrancescoDiMuro Click here to see my signature: Spoiler ALWAYS GOOD TO READ: Forum Rules Forum Etiquette
Developers Jos Posted September 23, 2018 Developers Posted September 23, 2018 (edited) mmm the only reason the first (now commented) fails is because there is a space missing before the first continuation character. Edit: so this works fine: ; This will give you "Error parsing function call." Local $intBit = BitOR( _ 1, _ 0) ConsoleWriteError($intBit & @CRLF) This does not: ; This will give you "Error parsing function call." Local $intBit = BitOR( _ 1, _ _ 0) ConsoleWriteError($intBit & @CRLF) Jos Edited September 23, 2018 by Jos 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.
FrancescoDiMuro Posted September 23, 2018 Posted September 23, 2018 @Jos Thanks for the tip, didn't know about that By the way, lookking closely at his function call: Local $sResult = _cFileSelectFolder( _ 'test', _ ; $title 'Desktop', _ ; $sTopItemText _ ; 'My Documents', _ ; $sTopItemText ; -----> This line of code '', _ ; $sInitPath $iWid, _ $iHt, _ $iLeft, _ $iTop, _ $hGui, _ ; $hParent $sExclFolders, _ $bHideHidden, _ $bHideSystem) Maybe that? Click here to see my signature: Spoiler ALWAYS GOOD TO READ: Forum Rules Forum Etiquette
Developers Jos Posted September 23, 2018 Developers Posted September 23, 2018 (edited) check my edit... that explains the issue of the initial post. PS: au3check used to check for the missing space before a continuation character but we had to disable that check due to other issues caused by that check. Jod Edited September 23, 2018 by Jos 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.
c.haslam Posted September 23, 2018 Author Posted September 23, 2018 Here is a simple case: #AutoIt3Wrapper_Au3Check_Parameters=-d -w 1 -w 2 -w 3 -w- 4 -w 5 -w 6 -w 7 foo('cat', _ 'white', _ _ ; 'black', _ 'short') Func foo($ani,$colour,$fur) MsgBox(0,'',$colour&' '&$ani&' has '&$fur&' fur') EndFunc Spoiler CDebug Dumps values of variables including arrays and DLL structs, to a GUI, to the Console, and to the Clipboard
Developers Jos Posted September 23, 2018 Developers Posted September 23, 2018 Just now, c.haslam said: Here is a simple case: #AutoIt3Wrapper_Au3Check_Parameters=-d -w 1 -w 2 -w 3 -w- 4 -w 5 -w 6 -w 7 foo('cat', _ 'white', _ _ ; 'black', _ 'short') Func foo($ani,$colour,$fur) MsgBox(0,'',$colour&' '&$ani&' has '&$fur&' fur') EndFunc I have already have posted a even simpler example in my earlier post. The issue is the continuation character on its own on a line as all comments are ignored. 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.
c.haslam Posted September 23, 2018 Author Posted September 23, 2018 Sorry. I was creating my example while you were posting. Is this issue to be considered as a bug? Spoiler CDebug Dumps values of variables including arrays and DLL structs, to a GUI, to the Console, and to the Clipboard
Developers Jos Posted September 24, 2018 Developers Posted September 24, 2018 No problem, and I don't know whether it is to be labelled as bug, but just post a simple scriptlet in TRAC to report it and let Jon determine whether this is a Bug. Jos 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.
c.haslam Posted September 24, 2018 Author Posted September 24, 2018 Will do Spoiler CDebug Dumps values of variables including arrays and DLL structs, to a GUI, to the Console, and to the Clipboard
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