Qbasicnews.com
Bug Reports - Printable Version

+- Qbasicnews.com (http://qbasicnews.com/newforum)
+-- Forum: General (http://qbasicnews.com/newforum/forum-6.html)
+--- Forum: General/Misc (http://qbasicnews.com/newforum/forum-18.html)
+--- Thread: Bug Reports (/thread-5202.html)

Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30


Bug Reports - ShadowWolf - 01-11-2005

ah man wish i saw the earlyer post would have saved me so much time Ah oh well live and learn.


Bug Reports - adosorken - 01-11-2005

I would personally have no problems with escape sequences as long as they were only effective for specific routines, kinda like in C how they work with printf but have no specific effects as normal char arrays. Big Grin


Bug Reports - SJ Zero - 01-11-2005

Why go with ~ rather than \ though? It seems like being different from C for the sake of being different than C, rather than for a legitimate reason, like going with ! or !@#! for pointers instead of *.

Personally, I'd like the new functionallity, but I'd also like it to be hidden unless a person wants to use it. A ParseEscapeChars (string) as string would probably be the best way to do the feature; that way it would be hidden from newbs who don't need to worry about it, but it would be immediately accessable for anyone who wanted to use the feature.


Bug Reports - Blitz - 01-11-2005

Becuase using \ as escape char would cause problems with existing programs for qbasic. It would interpret the \m in "mydir\myfile.fil" as an escape char. Everything in C isn't so great. This is one of them.


Bug Reports - SJ Zero - 01-11-2005

But if there was a parseEscapeChars command as I suggested, there would be no problems with anything, plus we could use standard escape codes. Smile


Bug Reports - v3cz0r - 01-11-2005

Ok, escape char is "\" now, compiler itself is using that in many parts so.. no way back ;)

"\" is easier to setup on some IDE's, "~"" would screw high-lighting so much that it would give ya brain damage after some seconds staring at it.

Be warned, if you use OPTION ESCAPE and than a bunch of '$include "" (using quotes "...", not apostrophes? '...'), don't forget to \\ the inc file path.. always use ' ' (apost..) inside include files, as you don't know if the user will put OPTION before or after the $include.. more ambiguity? That's BASIC..


Bug Reports - fsw - 01-11-2005

Quote:Be warned, if you use OPTION ESCAPE and than a bunch of '$include "" (using quotes "...", not apostrophes? '...'), don't forget to \\ the inc file path.. always use ' ' (apost..) inside include files, as you don't know if the user will put OPTION before or after the $include.. more ambiguity? That's BASIC..
Nope, that's inconsistency :o

If " are allowed it should work either way, in a bas or inc/bi files.

Sorry Victor, but please stick with one solution/way you choose and make it work everywhere in the code - also in include files.

BTW: I don't mind ditching " and use ' everywhere... Smile


Bug Reports - v3cz0r - 01-11-2005

That's the problem, i can't process escape chars by default and the inc files that include other inc files (the Win API ones for example) have no idea if escapes are on or off, i dunno if slashes '/' can be used on paths with old Windows versions (98? 95?).

Or i kill quotes used with $include or i won't add any other hack -- processing escapes also inside '...' is no sollution, see above.

Wtf did M$ use '...' with $include? Weird stuff..


Bug Reports - zydon - 01-11-2005

I'm suggesting a block methods for ESCAPE sequences because it sometimes only a single line from the whole source code need this support. Using OPTION will effecting the whole files. block switch such as:

Code:
#ESCAPE ON
print "He replied, \"Did I say something?\""
#ESCAPE OFF
print "Then he move the mouse pointer to c:\windows\system folder."
' print another paragraph ...
'...
' print another paragraph ...
#ESCAPE ON
print "He talk to himself again, \"Hmmm... I thought the DLL was there...\""
#ESCAPE OFF

this will give better control for the compiler start to replacing the escape chars and stop when #ESCAPE OFF found. List of supported escape characters also need to be decided on what is allow in FB.


Bug Reports - v3cz0r - 01-11-2005

Worst.. you must know if it's on/off, switching on or off is like DEF### when the QB IDE used to turn it DEFSGN before procs when you later inserted a DEFINT at top having the procs already declared..

Instead of
Code:
#ESCAPE ON
print "He replied, \"Did I say something?\""
#ESCAPE OFF

It would simpler to just
Code:
print "He replied, " + QUOTE + "Did I say something?" + QUOTE

Don't you think? ;) I know, it was just an example..