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

[REBOL] Re: Using a Math oper. buried in a variable

From: Scott:Wall:xwave at: 6-Apr-2009 12:59

Henrik wrote:
> It will not work, since / can't be directly converted to a word and > used as a get-word. The trick would be to write it first as a string > and convert it: > get to-get-word "/" > That is not very pretty, is it? (But keep it in mind, when you need to > convert something unwieldy to a word. :-))
Unfortunately, this approach doesn't seem to work on the "^^" operator.
>> op: get to-get-word "^^"
** Script Error: ^ has no value ** Near: op: get to-get-word "^^" I can however use :power. Shouldn't there be a consistent way to convert all operators from string to get-word? I am also trying to inject parentheses without much success. Is this even possible? I've tried: x: '( x: get to-get-word "(" x: :( Each attempt failed. Thanks, Scott.