On 7/14/05, Stefan Monnier <[EMAIL PROTECTED]> wrote:
> There's no released Emacs with defvaralias, so it's still recent.
That is true, but seems a joke... :)
> No. But I could make `defvar' un-const a defconst if that's necessary.
Aha.
> These are hard-read-only so they can't be redefined with defconst
> or un-const'd.
OK.
> Removing the defvars and replacing the setq with defconst is correct, but
> the byte-compiler is a bit dumb and don't realize that foo and bar are
> both unconditionally defined, so it may warn of unknown variables.
In this case you should `defvar' them (to make them known to the
byte-compiler), and then `defconst' them to make unmodifiable. If
there were ever to exist true constants in Emacs (which I see Richard
is vetoing), the ability to switch the constness state would be
necessary.
> - name clashes. E.g.
The only answer to this would be to make sure constants have
significant, hard-to-repeat-by-accident names. Instead of `e', that
should be `number-e' or `*number-e*' or `transcendent-constant-e' or
whatever.
> I doubt it'll ever make its way into Emacs:
That seems correct.
Thanks,
/L/e/k/t/u
_______________________________________________
Emacs-devel mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/emacs-devel