Well factory.h is a file generated by singular using this template:
https://www.singular.uni-kl.de:8005/trac/browser/git/factory/factory.template?rev=ee668eff445bb4cf7e96d94673c39f627a30d232
and that template 
uses: https://www.singular.uni-kl.de/dox/html/cf__defs_8h_source.html
Not really sure why they #define IntegerDomain 1 on line 25 there. But I 
guess that doesn't matter. It is just an occasion of having to different 
libraries accidentally using the same name for different things.

So this just means we should be careful with includes and other things so 
that these things don't clash.
Op vrijdag 3 december 2021 om 11:54:08 UTC+1 schreef Clement Pernet:

> Hi,
>
> Working on
>
>     https://trac.sagemath.org/ticket/32959
>
> I hit a compilation error due to
>
> sage/local/include/factory/factory.h: #define IntegerDomain 1
>
> which conflicts with
>
> sage/local/include/givaro/givinteger.h: using IntegerDomain = 
> ZRing<Integer>
>
> See the compilation log ;
>
> [sagelib-9.5.beta7] In file included from 
> /home/soft/sage/local/include/singular/coeffs/coeffs.h:19,
> [sagelib-9.5.beta7]                  from
> /home/soft/sage/local/include/singular/polys/monomials/ring.h:12,
> [sagelib-9.5.beta7]                  from 
> /home/soft/sage/local/include/singular/kernel/polys.h:15,
> [sagelib-9.5.beta7]                  from 
> /home/soft/sage/local/include/singular/kernel/structs.h:25,
> [sagelib-9.5.beta7]                  from
> /home/soft/sage/local/include/singular/Singular/libsingular.h:7,
> [sagelib-9.5.beta7]                  from
>
> build/cythonized/sage/rings/polynomial/multi_polynomial_libsingular.cpp:724:
> [sagelib-9.5.beta7] /home/soft/sage/local/include/givaro/givinteger.h: At 
> global scope:
> [sagelib-9.5.beta7] /home/soft/sage/local/include/factory/factory.h:92:23: 
> error: expected
> nested-name-specifier before numeric constant
> [sagelib-9.5.beta7]    92 | #define IntegerDomain 1
> [sagelib-9.5.beta7]       |                       ^
> [sagelib-9.5.beta7] 
> /home/soft/sage/local/include/givaro/givinteger.h:412:11: note: in 
> expansion of
> macro ‘IntegerDomain’
> [sagelib-9.5.beta7]   412 |     using IntegerDomain = ZRing<Integer>;
> [sagelib-9.5.beta7]       |           ^~~~~~~~~~~~~
>
> I have no clue what is this Factory, and why it defines IntegerDomain to 1.
>
> Any insight would be most welcome.
>
> Cheers.
>
> Clément
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-devel/41bfbe41-5c62-428a-bd93-a5a2c0c5a0e3n%40googlegroups.com.

Reply via email to