Dear Bill,
Your code (which I copied and pasted into monad2.spad):
> Here is some more realistic example code that does compile and run:
>
> )abbrev domain MYSET MySet
> MySet(T:SetCategory): SetAggregate(T) with
> finiteAggregate
> join: MySet % -> MySet T
> == add
> Rep == List T
> --rep(x:%):Rep == x pretend Rep
> --per(x:Rep):% == x pretend %
>
> Rep2 := List List T
> rep2(x:MySet(%)):Rep2 == x pretend Rep2
> per2(x:Rep2):MySet(%) == x pretend MySet(%)
>
> coerce(x:%):OutputForm == brace [i::OutputForm for i in rep x]
> x = y == rep(x) = rep(y)
> construct(x) == per removeDuplicates(x)$Rep
> parts(x:%):List T == rep x
> join x == construct concat rep2 x
>
(1) -> )co monad2
Compiling FriCAS source code from file
/home/fauser/fricas/monad2.spad using old system compiler.
MYSET abbreviates domain MySet
------------------------------------------------------------------------
initializing NRLIB MYSET for MySet
compiling into NRLIB MYSET
compiling local rep2 : MySet $ -> Rep2
MYSET;rep2 is replaced by x
Time: 0.03 SEC.
compiling local per2 : Rep2 -> MySet $
MYSET;per2 is replaced by x
Time: 0 SEC.
compiling exported coerce : $ -> OutputForm
Internal Error
Error while instantiating type MySet$$
?
Cheers
BF.
--
% PD Dr Bertfried Fauser
% Research Fellow, School of Computer Science, Univ. of Birmingham
% Honorary Associate, University of Tasmania
% Privat Docent: University of Konstanz, Physics Dept
<http://www.uni-konstanz.de>
% contact |-> URL : http://www.cs.bham.ac.uk/~fauserb/
% Phone : +44-121-41-42795
--
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.