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

[REBOL] append Re:(2)

From: rebol:techscribe at: 14-Aug-2000 15:10

Hi Galt, a few minor comments: you wrote: [snipped correct and useful insights]
>It appears that on the second call, when >count = 1, then the local dirtree is not initialized,
Actually, local words are initialized to the value none (as are refinements):
>> f: func [/local word] [ print word ] >> f
>and Rebol does not have a type for its unset value.
The type of unset words is unset!:
>> type? ;- there ain't nothin' here for type?
== unset!
>Therefore it complains about the type not being series value.
Therefore: i.e. because the value of dirtree is none, and none's type is none!, which is not one of the types required by append. If the word was indeed unset, then you would get a different error:
>> f: func [/local word] [ unset 'word append word "something to append" ] >> f
** Script Error: word has no value. ** Where: append word "something to append" Hope this helps. ;- Elan [ : - ) ] author of REBOL: THE OFFICIAL GUIDE REBOL Press: The Official Source for REBOL Books visit me at