emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Contribution to SES (resend)


From: Stefan Monnier
Subject: Re: Contribution to SES (resend)
Date: Fri, 23 Apr 2010 02:24:00 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux)

> This was my orginal idea, but then I thought that ses-range being a
> slightly faster implementation, it might be valuable to keep it. 

I don't think the speed difference is significant enough to warrant
the duplication.

> Actually the very main reason for both to coexist is that the default
> orientation for ses-range is `<^', while the default for ses-list is
> `>v'. I find it very convenient to have >v because this is the usual
> orientation in the Western world (even though this is not universal, I
> am a westerner after all). And all spreadsheets I know have cell (0,0)
> in the top left corner, so it is good to have this orientation by
> default.

And a different default doesn't seem like a strong enough
justification either.  You can easily add >v to your uses if you prefer it.

Please just change the default of ses-list to be compatible with
ses-range and rename it to ses-range (a more informative name,
methinks).

>> - Hmmm.... #N= + #N# in source code ... I'd rather avoid it.
> Does the compiler factorize code well ?

It doesn't.  And if you use #N=...#N# to make cyclic code, it will
happily loop forever.

> BTW `^>' is not the reverse of `>^'.

Yes, the multi-dimensional case probably justifies the complexity.

>> - please use `case' rather than assq+eval (I usually dislike `eval').
> Do you mean `cond', not `case' ? Please clarify.

No, I mean `case'.  It's a CL macro.

> Why do you dislike `eval' ? (I am a curious one).

Because it hides code from the compiler.

>> - The !0 and !. should be replaced by a single flag that comes with
>> the default value to use.
> OK, I like your idea. So `!' could be to remove nil and *skip* and `_ 0'
> would replace them by 0, and, if `_' is last, default of default would
> be 0. Would this be fine (notably `_' to mean blanking by some default).

That sounds OK, yes.

>> - I'm not convinced I like those special symbols (but I don't have
>> a good counter-proposition either).
> Please feel free to make one. I was thinking first of taking the picture
> orientation symbols > < ^ . / \ ' and `. But then I find that those I
> proposed are easier to understand: you don't read a table in diagonal,
> don't you (I don't know whether you can say that in English "lire en
> diagonale", to mean "read without carefull attention").

> Maybe we could also have those shorthands :

>  | one letter symbol | meaning |
>  |-------------------+---------|
>  | >                 | >v      |
>  | <                 | <v      |
>  | v                 | v>      |
>  | ^                 | ^>      |
 
> Would this make sense (notably for one row, or one col tables where you
> don't care the other direction) ?

These are still special symbols, so they're not any better, in my opinion.


        Stefan




reply via email to

[Prev in Thread] Current Thread [Next in Thread]