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

[REBOL] Re: adding set-words to a context from outside

From: ingo:2b1 at: 12-Oct-2001 11:06

Hi Anton, try Once upon a time Anton Rolls spoketh thus:
> Does anyone know how to add > words to an object from outside > that object? > > For example, take an empty object o: > > o: context [] > > ; Now some voodoo stuff happens > ; here that adds a word to o
o: make o [a: none]
> ; and the result... > > probe o > > make object! [ > a: none > ]
But remember, that 'make doesn't create deep copies, so you might run into some surprises, if you tried to assign this to another word. But setting it back to the same is safe. kind regards, Ingo