David Bovill wrote:
2009/12/31 Jim Ault <jimaultw...@yahoo.com>
  --// html honors both quote types, ignores extra spaces
Thanks Jim !! How did I get to this age in my life without realizing that !?
NB - I do think that RunRev should add syntax to the language to make html
quoting very easy to use for both iRev scripts We need an elegant solution
to quoting html - other languages are easier to use and read with regard to
html quoting! using our own custom functions does not make read/writeability
that much easier, and makes it harder to share scripts.
My first choice would be to allow either single or double quotes to delimit strings - then I could put the other kind within it without any problems (yep, idea borrowed from Python, amongst others).

So we could go one step further and also borrow from Python a neat method of allowing multi-line strings. Instead of using *one* quote at start+end of the string, you use *three* of them (which is unambiguous with any existing valid code, afaict). So in revTalk terms, I could do

put 'I said "This way!"' into tVar

put "it's mine" into tVar

put """
this is a long
multi line string.
I'd say "It's easy to embed quotes within it !!"
""" into tVar

Note the starting triple-quote has to be last item on line, and the closing triple-quote has to be first item on its line - and the first/last CR within the text are not part of the resulting string.
My suggestion is to extend the syntax for local variables and constants.
Currently we have:

Hmmm :-( I'd much rather find a syntax that works equally for local, constants and plain old expressions - see above.

-- Alex.
_______________________________________________
use-revolution mailing list
use-revolution@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-revolution

Reply via email to