Re: why macsyma commercial share packages are compiled
Subject: Re: why macsyma commercial share packages are compiled
From: Stavros Macrakis
Date: Fri, 2 May 2003 15:40:50 -0400
> A compiler will generally find and warn at compile time about
> misspellings and incorrect syntax.
This could be true in principle, but pretty much false in practice for
the Maxima translator/compiler.
Though the Maxima language is semantically a lot like Lisp, it is
syntactically a lot like Algol. So essentially all syntax errors are
found at read time, not at compile time -- you don't have things like
Lisp's (cond foo bar) which gets read correctly but is incorrect syntax.
The Translate package doesn't really detect many semantic errors. It
does warn the user of the undeclared use of global variables. On the
other hand, it doesn't object to cons(x,2) (second argument must be a
list) or cons(x,x,x) (wrong number of arguments) or x/0 (divide by zero)
or undefined function references etc. etc.
So you are getting very little compile-time checking out of Translate
and Compile.
That said, I don't see much harm in precompiling Share packages. The
only downside is that execution errors won't be debuggable using the
Maxima debugger. But the Maxima debugger is not exactly a very handy
tool....
-s