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

[REBOL] Re: Strange behavior for dirs and files

From: greggirwin:mindspring at: 22-Feb-2003 11:16

Hi Robert, RMM> Hi, I have the following code snippet which is part of an IOS (link-app) RMM> Reblet: RMM> ;read in current directory RMM> cd: read this-folder RMM> ; filter out all directories RMM> dirs: make block! [] RMM> foreach entry cd [probe reduce [entry type? entry dir? entry file? RMM> entry] if dir? entry [append dirs entry]] RMM> ?? dirs RMM> Why does dir? Return false for all entries? I really don't have a clue RMM> what's up. Is %documents/ the current directory (i.e. what WHAT-DIR returns)? If not, that would explain it I think. If you don't have a fully qualified path for a file, REBOL uses the current directory when checking things. -- Gregg