hiding auxiliary definitions



Customary is (in order)
1. ignore the possibility of name conflicts
2. use strange prefixes.

This is not ideal.
RJF


Albert Reiner wrote:

>Hi,
>
>unless I have read the documentation wrong, there is nothing like
>packages or namespaces etc. in Maxima.  So what do you do to keep
>auxiliary definitions from getting into the way of the user?  I can
>see these possibilities:
>
>- use "unlikely" names, via some naming convention such as a prefix,
>  e.g., my_prefix_auxiliary(x):=...: A user who calls a function
>  starting with my_prefix_... presumably knows what he does; however,
>  these long identifiers are quite inconvenient when writing the
>  actual code.
>
>- make the auxiliaries part of the real function,
>  e.g. foo(x):=block([auxil: lambda(...)], ...): This makes it
>  difficult to test the auxiliary by itself, it does not work with
>  macros, it's unmodular, and you get into trouble when one auxiliary
>  is used by several definitions.
>
>- wrap everything with a macro that checks whether a symbol already
>  exists, and replaces it with a prefixed version: I don't know
>  whether this would work.
>
>- ignore the possibility of name conflicts.
>
>Anything I am missing?  And what is customary?
>
>TIA,
>
>Albert.
>
>_______________________________________________
>Maxima mailing list
>Maxima@www.math.utexas.edu
>http://www.math.utexas.edu/mailman/listinfo/maxima
>  
>