Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

strange StackOverflowError when instantiating a polynomial #1363

Closed
sumiya11 opened this issue Dec 15, 2022 · 2 comments
Closed

strange StackOverflowError when instantiating a polynomial #1363

sumiya11 opened this issue Dec 15, 2022 · 2 comments

Comments

@sumiya11
Copy link
Contributor

using Nemo

F = GF(2);
R, (x,) = PolynomialRing(F, ["x",]);
R([F(1)], [[Int(1)]])
> x
R([F(1)], [[BigInt(1)]])
> x

F = FqNmodFiniteField(fmpz(2), 2, :z);
R, (x,) = PolynomialRing(F, ["x",]);
R([F(1)], [[Int(1)]])
> x
R([F(1)], [[BigInt(1)]])
ERROR: StackOverflowError:
Stacktrace:
  [1] _collect(c::Vector{fq_nmod}, itr::Base.Generator{Vector{fq_nmod}, FqNmodFiniteField}, #unused#::Base.EltypeUnknown, isz::Base.HasShape{1})
    @ Base .\array.jl:812
  [2] collect_similar
    @ .\array.jl:716 [inlined]
  [3] map
    @ .\abstractarray.jl:2933 [inlined]
  [4] (::FqNmodMPolyRing)(b::Vector{fq_nmod}, m::Vector{Vector{BigInt}}) (repeats 26097 times)
    @ AbstractAlgebra C:\Users\User\.julia\packages\AbstractAlgebra\Oe2Uj\src\MPoly.jl:1221
  [5] eval
    @ .\boot.jl:368 [inlined]
  [6] eval
    @ .\Base.jl:65 [inlined]
  [7] repleval(m::Module, code::Expr, #unused#::String)
    @ VSCodeServer c:\Users\User\.vscode\extensions\julialang.language-julia-1.38.2\scripts\packages\VSCodeServer\src\repl.jl:222
  [8] (::VSCodeServer.var"#107#109"{Module, Expr, REPL.LineEditREPL, REPL.LineEdit.Prompt})()
    @ VSCodeServer c:\Users\User\.vscode\extensions\julialang.language-julia-1.38.2\scripts\packages\VSCodeServer\src\repl.jl:186
  [9] with_logstate(f::Function, logstate::Any)
    @ Base.CoreLogging .\logging.jl:511
 [10] with_logger
    @ .\logging.jl:623 [inlined]
 [11] (::VSCodeServer.var"#106#108"{Module, Expr, REPL.LineEditREPL, REPL.LineEdit.Prompt})()
    @ VSCodeServer c:\Users\User\.vscode\extensions\julialang.language-julia-1.38.2\scripts\packages\VSCodeServer\src\repl.jl:187
 [12] #invokelatest#2
    @ .\essentials.jl:729 [inlined]
 [13] invokelatest(::Any)
    @ Base .\essentials.jl:726
 [14] macro expansion
    @ c:\Users\User\.vscode\extensions\julialang.language-julia-1.38.2\scripts\packages\VSCodeServer\src\eval.jl:34 [inlined]
 [15] (::VSCodeServer.var"#61#62")()
    @ VSCodeServer .\task.jl:484

On Nemo v0.32.6

@thofma
Copy link
Member

thofma commented Dec 15, 2022

Thanks for the report. I can reproduce it and a fix is incoming.

tthsqe12 added a commit that referenced this issue Dec 15, 2022
@sumiya11
Copy link
Contributor Author

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants