[REBOL] Re: Pre-REP on NONE! and SERIES! polymorphism
From: carl:cybercraft at: 12-Jun-2002 18:50
Hmm. Forgot to hit Send on this yesterday... (:
On 11-Jun-02, Ladislav Mecir wrote:
> Hi all,
> I do not hate polymorphism! That said, I must say, that all proposed
> solutions look like "an exception to an exception".
> 1) I do not think, that NONE is an ideal replacement for an empty
> block.
I agree. My feeling is that if something may return none or an empty
block then there's a difference there for some reason and perhaps you
should be checking for it.
> 2) I do not think, that NONE is good at pretending to be a LOGIC!
> value.
Actually, I like that. I like to be able to use the likes of...
if file-names: request-file [process file-names]
and so on. I wouldn't like an empty block to be treated as false in
such a case though.
--
Carl Read