Case-sensitivity goals, policy and implementation



>>>>> "James" == James Amundson <amundson@users.sourceforge.net> writes:

    James> Everyone,
    James> I would like to present a slightly modified plan for case sensitivity in
    James> Maxima. Even though we have already discussed this subject at great
    James> length, I believe a little more discussion is warranted. The change in
    James> case-sensitivity is something we should do only once, so it is important
    James> that we end up with a plan that will stand the test of time.

    James> First, let me state the goals of the new plan:

    James> 1) Maxima should make it as easy as possible to represent mathematical
    James> expressions used in hand calculations.

    James> 2) Maxima's behavior with respect to case should be simple enough to
    James> easily explain to users familiar with contemporary programming languages
    James> and consistent with basic software engineering principles.

    James> 3) Maxima should continue to interact well with ANSI Common Lisp.

    James> (These goals could probably be stated more clearly, but I don't think
    James> it's worth spending a week working on wording.)

Could these goals be achieved by doing basically what Lisp would
consider :preserve-case and :invert-case?

The case is preserved, but it is inverted.  So typing "sin" in maxima
would invert the case so it looks like SIN in lisp.  Typing "SIN" in
maxima would give |sin| in Lisp.  And they'd be all different.  And on
output, we'd invert-the case too, so Lisp SIN is printed as sin.  So
for typical lower case code, we get easy typing from Lisp, but we
still distinguish case as desired.  Of course, if someone does "Sin",
the Lisp name would be |sIN|.  Oh well.

But I must be one of the few who wishes maxima weren't case-sensitive
at all.  I rarely use case to distinguish anything in any
language. :-)

Ray