Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search

[REBOL] Re: REBOL embedded $variables

From: fsievert:uos at: 9-Dec-2002 19:55

> Those of you who are familiar with Unix shell scripts and languages like > Perl know the usefulness of being able to evaluate variables embedded in > arbitrary text. For example, you might write a line like: > > <A HREF="$page"> > > where the evaluation of $page is substituted. This is pretty common.
This would mean, REBOL has to look in all any-strings for "$" whenever they are evaluated? And it must be copied. Not good. You would have to add more evaluation-exceptions in your stack-machine. For example: url: "$url" == ... a: <a href="$url"> == <a href="$url"> a == <a href="$url"> ??? The url is evaluated a second time here Doing at load-time would be a bad idea, too.