Re: [fricas-devel] Numbers as type parameters

2022-09-01 Thread Kurt Pagani
Thanks for this elaborate explanation - a real eye-opener and hint for a (pseudo) work-around :) When we change Impl B to (using _0,_2,...): Implementation == BOP add Rep := BOP coerce(s:Symbol):% == operator s _0:PINT _2:PINT r:Polynomial Integer

Re: [fricas-devel] Numbers as type parameters

2022-09-01 Thread Waldek Hebisch
On Thu, Sep 01, 2022 at 07:32:00PM +0200, Kurt Pagani wrote: > On 01.09.2022 19:11, Waldek Hebisch wrote: > > On Thu, Sep 01, 2022 at 09:11:33AM -0700, Kurt Pagani wrote: > >> Problem: when using a type A(p:Polynomial Integer) in another type B, then > ... > > > > ATM I see no chance to make

Re: [fricas-devel] Numbers as type parameters

2022-09-01 Thread Kurt Pagani
On 01.09.2022 19:11, Waldek Hebisch wrote: > On Thu, Sep 01, 2022 at 09:11:33AM -0700, Kurt Pagani wrote: >> Problem: when using a type A(p:Polynomial Integer) in another type B, then ... > > ATM I see no chance to make this working. Let me recall what I wrote > im March 2021: > > : However,

Re: [fricas-devel] Numbers as type parameters

2022-09-01 Thread Waldek Hebisch
On Thu, Sep 01, 2022 at 09:11:33AM -0700, Kurt Pagani wrote: > Problem: when using a type A(p:Polynomial Integer) in another type B, then > Fricas complains if p is a number (Expression makes no difference). Is > there any method to tell the compiler that the number (if) is a "Polynomial >

[fricas-devel] Numbers as type parameters

2022-09-01 Thread Kurt Pagani
Problem: when using a type A(p:Polynomial Integer) in another type B, then Fricas complains if p is a number (Expression makes no difference). Is there any method to tell the compiler that the number (if) is a "Polynomial Integer"? I tried out as much as crossed my mind. Any clues highly