[REBOL] Re: ROUND function (like TRUNC, FLOOR, etc...)
From: carl:cybercraft at: 20-Feb-2002 19:39
On 20-Feb-02, Charles wrote:
> I do not believe I've come across these three in my (highly
> limited) studies. Is there a decent reference to them in "REBOL For
> Dummies", or one of the online guides? (Preferrably a non-PDF
> guide.) Thanks.
Others can have a go at 'context, but the other two are just function
'does is for functions with no arguments or locals so instead of...
say-something: func [print "something"]
you can have...
sat-something: does [print "something"]
while 'has is for functions with locals but no arguments. So instead
a: func [/local n][n: 10 do-something-using n]
you can have this...
a: has [n][n: 10 do-something-using n]
'does at least can save a lot of empty blocks apearing in your
>> On 19-Feb-02, Joel Neely wrote:
>>> I realize that this is not a perfect model (given the existence
>>> such trivial shortcuts as CONTEXT, DOES, and HAS) but nobody's
>>> perfect! ;-)
>> Trivial they may be, but I use 'does extensively and 'has often,
>> so they're very useful shortcuts. I don't think I'd use a rounding
>> function in nearly every script like I do those two words.
>> Carl Read