[REBOL] Combining a word and a value in one argument
From: tim:johnsons-web at: 26-Sep-2000 19:00
I'm sending this again. I sent this earlier with another email.
It arrived, this didn't, so am trying again.......
;======================
Howdy:
It would be great if I could have a function that
would take a rebol word as an argument and
print out both the word and it's value:
i.e:
test-int: 4
tst test-int
>>test-int: 4
This would be similar to a c function using the preprocessor
stringizer
as in #define PRINT(x) print(x,#x)
print(int x,char* x_name)
{
return printf("%s: %d",x_name,x);
}
test-int = 4
PRINT(test-int); // gives test-int: 4
I tried playing with first system/words but couldn't come up
with anything consistant.
TIA
-Tim