Strange, indeed. The CATs seem to be ok.
When taking minrootpol and CX out of the body of f2, the it works.


)abbrev package BAR Bar
Bar(C: IntegralDomain): with
    f1: () -> Void
    f2: () -> Void
  == add

    minrootpol: SUP C := monomial(1,2)$SUP(C) + 1
    CX:=SimpleAlgebraicExtension(C, SUP C, minrootpol)

    f1(): Void ==
      px1 := px()$Foo(C, L1 C)
      dbgPrint("px1", px1)

    f2(): Void ==
      px2 := px()$Foo(CX, L1 CX)
      dbgPrint("px2", px2)

   Bar is now explicitly exposed in frame initial
   Bar will be automatically loaded when needed from
      /Users/kfp/AppData/Local/Temp/BAR.NRLIB/BAR

(3) -> f2()$BAR(FRAC INT)
                       2    3
   [:> , px2, 1 + q + q  + q ]
                                                                   Type: Void
(4) -> f1()$BAR(FRAC INT)
                       2    3
   [:> , px1, 1 + q + q  + q ]
                                                                   Type: Void
(5) ->




On 03.11.2020 23:35, Waldek Hebisch wrote:
> On Tue, Nov 03, 2020 at 11:07:14PM +0100, Ralf Hemmecke wrote:
>> Hi Kurt, hi Waldek,
>>
>> I really cannot make sense out of the error in the attached program.
>> Why would it in some cases work fine and in others not? That is quite
>> frustrating. Anyone spots an error in my code? Or is it another compiler
>> bug?
> 
> First guess is that this is due to different handling of constants
> in types in various part of FriCAS (this is known bug).
> Try consitently keeping parameters as variables and pass actual
> values from interpeter only at one place.
> 

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/fricas-devel/b4683e68-a31d-5b56-124a-3b6c7d8e712b%40gmail.com.

Reply via email to