>>>>> "Klaus" == Klaus Berndl <Berndl> writes:
Klaus> No, here i do not agree with you and Stephen. Reasons:
Klaus> - Changing current `window-list' so it always returns a somehow canonical
Klaus> ordered list is very simple and has really no disadvantage (at least as fas
Klaus> i can see)
>Yes, it has, namely that people tend to then rely on that canonical
>order, even though it's not part of the natural specification---this
>makes it impossible to change later, should it become opportune to do
>so. (If it's one thing XEmacs history has taught us, then that's it,
>thank goodness.)
Hmm, IMHO a somehow "contructed" argument and disadvantage. See `next-window'
and the documentation (just the first few lines):
"`next-window' is a built-in function
(next-window &optional WINDOW MINIBUF WHICH-FRAMES WHICH-DEVICES)
Documentation:
Return the next window after WINDOW in the canonical ordering of windows.
If omitted, WINDOW defaults to the selected window.
..."
You see the word "canonical"??!! I really can not imagine what good reason should
exist (or even in any future come up) which would make sense and necessary to
change the order from the canonical one to any other.
If i understand you right then you say it is best to make no specification
for API-functions on which programmers can rely because maybe someone wants
to change it later and then all already existing code fails or has to be
rewritten, right?
Yes, of course this is true for inhertitance-hierarchies in OO-programming etc..
and some other design issues too but really not for defining a senseful order of
a result list especially if the same order is already there (and also documented)
In other API-functions e.g. in `next-window'. Then i'm wondering why you XEmacs-
people have defined the order of `next-window', because now it is impossible
to change the order, `next-window' will select the next window - which is IMHO good,
that this is impossible!!
Sometimes concret and clear specifications of API-functions are really helpful and
necessary especially for stable applications this is what years of designing and
programming of big applications has taught me, thang goodness.
Back to window-list: Cause of really no order-specification of this function i have
to write my own window-list function if i want this canonical order which is IMHO
complete waste of time and code because there is already one. At least a further
optional argument "order-canonical" could be added so i can apply this order to the
list if i want (without programming the whole stuff again).
Compare it with SQL: Here you have also no order specification but you CAN apply
someone if you NEED any!
Ok, such an additional optional parameter for `window-list' would satisfy both of
us, you because you can change the default order of window-list whenever you
want and me, because i have to program the whole function again though there is
already one.
Thoughts?
Ciao,
Klaus