Charles Steinman wrote:

> > > Just put "def exit() 'Use Ctrl-D (i.e. EOF) to exit.' end" in your
> > > ..irbrc file. Then you'll never have to worry about it again.

> > The problem isn't exit, but quit.
 
> My bad. The "exit" in the Python response threw me off. You can do the
> same with quit, though.

Yes.  It seems they were in such a hurry to add that message that they
never considered that not all people draw a mental parallel between
°»quit°… and °»exit°….  Also, they forgot a comma efter the °»i.e.°… (yes, I
am _that_ anal retentive).

> > > Personally, I don't have a problem with involuntarily typing
> > > "exit" into IRB. Anyway, the exit method is part of the standard
> > > library, not a function of IRB. I don't think changing it by
> > > default in IRB would be a good thing.

Man, I thought you were playing along here (see below).

> > Hm, perhaps not.  One could give it a counter, so that if I type
> > quit twice in a row it'll first warn me that I should be uisng ^D,
> > and then the next time it'll actually quit,

> I still don't understand why quit should be an exception to every
> other method, including the functionally identical exit. And isn't
> accidentally typing ^D about as easy as accidentally typing "quit"? It
> seems actually easier to me, since it's only one off from a normal
> capital D whereas "quit" is four letters long.

Didn°«t you read the subject?  I°«m being very sarcastic actually.  My
intent was to point out that instead of simply adding a hook for quiting
the interpreter when the user types °»quit°…, the Python people added a
message that says how you should exit properly instead.

If I type °»quit°… or °»exit°… in a TUI, I expect the application to exit,
returning me to the terminal.  Instead of doing that they force me to
use ^D, which one has to be a pretty advanced UNIX user to know about (I
do, but I can see how many new users won°«t),
        nikolai

-- 
Nikolai Weibull: now available free of charge at http://bitwi.se/!
Born in Chicago, IL USA; currently residing in Gothenburg, Sweden.
main(){printf(&linux["\021%six\012\0"],(linux)["have"]+"fun"-97);}