Bill, I changed my mind about retractIfCan/RetractableTo, so
Bill, Ralf and me should on the same page.

About 'coerce : R -> Maybe R', this auto-coercion only works at
interpreter, right?  So when writing Spad, one should explicitly
use 'wrap' (or 'coerce', but 'wrap' is more clear).

About 'retract : Maybe R -> R', it should do error checking, as other
'retract' do.  And when writing Spad, one can use 'unwrap(x)' or
'retract(x)', but not 'x::R' like we used to when using Union("failed",...),
or should we?  By adding 'convert : Maybe R -> R' (with error checking)?

A lot of current code use :: to retract from Union("failed", R) to R,
I experienced that in the previous commit.

I'm inclined to have this '::' conversion,  because '::' is still explicit.
Frankly, the compiler trick that let you omit the '::' conversion is not
used many times, and that trick is not always available.

-- 
You received this message because you are subscribed to the Google Groups 
"FriCAS - computer algebra system" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/fricas-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to