Bill Page wrote:
>
> "domains are constructed at runtime"
>
> OK sure, although I could quibble over what "constructed" means here.
> But the point is that once constructed domains to not change. They are
> static.
For most types yes. But note that in Spad once "constructed"
integers do not change: when you assign value of integer
expression to a variable, old value is discared and new value
is created. In other words ingerers, booleans and most types
are immutable. There are also mutable values, primary example
beeing records and arrays. Some types are mutable in the
sense that they store values inside and stored value changes
during execution -- primary example is given by Float
(you can change precision).
Types are dynamic in the sense that you can assign them to
variables, pass as arguments to functions and return them
from functions and actual values involved are determined
only at runtime. If you compare that to integers you see
that the difference is that there is limited number of
operations working on types, while you have a lot of
functions to handle integers.
One way to produce new types is to pass parameters to
type constructor. This is most frequent way and the
_only_ one for categories. OTOH for normal types you
can use arbitrary computations to produce them.
--
Waldek Hebisch
[email protected]
--
You received this message because you are subscribed to the Google Groups
"FriCAS - computer algebra system" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/fricas-devel?hl=en.