Zebol (was ordinal cardinal)..
[1/3] from: joel::neely::fedex::com at: 9-Jul-2001 11:56
Hi, Jeff,
Jeff Kreis wrote:
> Howdy, Joel:
>
> > It is, of course, much simpler simply to do without
> > features that affect the global state. Just imagine the
> > chaos that could ensue if, for example, we allowed a
> > function to change the current directory, close a file, or
> > modify a global variable... The mind boggles! ;-)
>
...
> It's essentially "critical section" code, and would make
> programming REBOL Z-based like programming a device driver,
> not very appropriately equated in consequences to:
>
> "change the current directory, close a file, or modify a
> global variable..."
>
Bearing in mind the role that exaggeration and sarcasm has had
in the discussion, I had thought that the ";-)" suffix would
serve as an adequate indicator that I wasn't totally serious.
(I seem to recall someone posting a message that exaggerated
a discussion of indexing bases into a proposal for fully
parenthesized expressions and mandating Polish postfix...
Surely we're all entitled to *some* amount of humor? ;-)
However, I *will* say that the kinds of bugs that arise from the
so-called "side effects" of massaging global data or state are
so well documented that we're really talking about a quantitative
difference rather than a qualitative one -- the main question is
how much risk one is willing to take.
As a horrible example of this problem gone to seed, I recall a
database language from a few years ago that had quite a number
of global variables that affected the behavior of several
language constructs. Even worse (fatally IMHO) it was missing
any means to *read* some of them, which meant that it was
practically infeasible to write well-mannered routines that would
save the state, do whatever, and then restore the state.
Truly a nightmare!
> But, as you say, you're not arguing for a global Z setting --
> so that's neither here nor there.. (-:
>
Agreed.
-jn-
___________________________________________________________________
One is the loneliest number...
- Three Dog Night
joel'dot'neely'at'fedex'dot'com
[2/3] from: jeff:rebol at: 9-Jul-2001 18:43
Howdy, Joel:
> > [zebol] it's essentially "critical section" code, ...
> > ... not very appropriately equated in consequences
<<quoted lines omitted: 6>>
> would serve as an adequate indicator that I wasn't totally
> serious.
You bet. I similarly decked my arguement out with the
latest in (-: accessories .. (down in the here nor there
part). ;)
> (I seem to recall someone posting a message that
> exaggerated
> a discussion of indexing bases into a proposal for fully
> parenthesized expressions and mandating Polish postfix...
> Surely we're all entitled to *some* amount of humor? ;-)
Humbug. Humor is only allowed if you send in an article to
the Zine. Your dispensation from the last one's nearly run
out! (-: Haw haw.
-jeff
_________________________________________________________________
> "One is the loneliest number..." -Three Dog Night
>
> joel'dot'neely'at'fedex'dot'com
"Drop that zero and get you a hero" --Any given 90's daytime TV
talkshow audience member
"He's a real nowhere man ... " --The Beatles
[3/3] from: jeff:rebol at: 8-Jul-2001 9:19
Howdy, Joel:
> A routine that has some reason to twiddle a global switch
> accepts responsibility for saving the state of the global,
<<quoted lines omitted: 5>>
> function to change the current directory, close a file, or
> modify a global variable... The mind boggles! ;-)
My mind boggles at your comparisons. (-;
a-z-fun: does [
system/options/index: 0
-- Some Code --
system/options/index: 1
]
What can go in Some Code? Well anything as long as you don't
call ANY mezzanines or native functions that may end up using
any series actions or functions that expect a 1 base universe.
Otherwise results will be UNPREDICTABLE. It's subtle/complex,
and very prone to creating hard to trace bugs that may not
show up until long after the fact.
It's essentially "critical section" code, and would make
programming REBOL Z-based like programming a device driver,
not very appropriately equated in consequences to:
change the current directory, close a file, or modify a
global variable...
But, as you say, you're not arguing for a global Z setting --
so that's neither here nor there.. (-:
>> On second thought, replicating all the series actions is
>> sounding much more preferable...
>
> We can certainly agree on that.
The more I think about the z question, the more I am annoyed
at the problem because I can't see (or have yet to have
seen) a truly graceful, simple, REBOL-like way of adding it
into the language. Expedience makes for crummy design. I
want to argue against something that I think may be a
mistake for REBOL, or may be an ugly addition like a big
condo development that wrecks the view-- sure people need
houses, but do we have to just throw up any old box with
windows on the nicest hills in the valley? No offence.
-jeff
Notes
- Quoted lines have been omitted from some messages.
View the message alone to see the lines that have been omitted