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

fix some 1.5 compatibility issues #35965

Merged
merged 1 commit into from
May 21, 2020
Merged

fix some 1.5 compatibility issues #35965

merged 1 commit into from
May 21, 2020

Conversation

JeffBezanson
Copy link
Member

  • restore some copyto! methods that Knet assumed existed
  • allow findfirst to work on InfiniteArrays again
  • allow constructing a LineNumberNode from a String

- restore some `copyto!` methods that Knet assumed existed
- allow `findfirst` to work on InfiniteArrays again
- allow constructing a LineNumberNode from a String
@ararslan ararslan merged commit 853fe04 into master May 21, 2020
@ararslan ararslan deleted the jb/1.5issues branch May 21, 2020 21:00
KristofferC pushed a commit that referenced this pull request May 25, 2020
- restore some `copyto!` methods that Knet assumed existed
- allow `findfirst` to work on InfiniteArrays again
- allow constructing a LineNumberNode from a String

(cherry picked from commit 853fe04)
@@ -1762,8 +1774,8 @@ CartesianIndex(1, 1)
```
"""
function findnext(testf::Function, A, start)
i = oftype(first(keys(A)), start)
Copy link
Contributor

@goretkin goretkin Aug 7, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably prompted by

https://github.com/JuliaCI/NanosoldierReports/blob/18bb6d85b20e25f1a9f2f312963f4b8b4fe7082e/pkgeval/by_hash/a340bf1_vs_3c50b7f/logs/ApproxFun/1.5.0-DEV-fc8aa8666a.log#L260-L288

Periodic: Error During Test at /home/pkgeval/.julia/packages/ApproxFun/IC3js/test/ReadmeTest.jl:75
  Got exception outside of a @test
  MethodError: no method matching InfiniteArrays.Infinity(::Int64)
  Closest candidates are:
    InfiniteArrays.Infinity(::T) where T<:Number at boot.jl:715
    InfiniteArrays.Infinity() at /home/pkgeval/.julia/packages/InfiniteArrays/aQOI9/src/Infinity.jl:15
    InfiniteArrays.Infinity(!Matched::Float16) where T<:Integer at float.jl:71
    ...
  Stacktrace:
   [1] convert(::Type{InfiniteArrays.Infinity}, ::Int64) at ./number.jl:7
   [2] oftype(::InfiniteArrays.Infinity, ::Int64) at ./essentials.jl:367
   [3] findnext(::ApproxFunBase.var"#286#287"{Int64}, ::InfiniteArrays.InfStepRange{Int64,Int64}, ::Int64) at ./array.jl:1766
   [4] findfirst(::Function, ::InfiniteArrays.InfStepRange{Int64,Int64}) at ./array.jl:1820
   [5] block(::ApproxFunBase.SumSpace{Tuple{CosSpace{PeriodicSegment{Float64},Float64},SinSpace{PeriodicSegment{Float64},Float64}},PeriodicSegment{Float64},Float64}, ::Int64) at /home/pkgeval/.julia/packages/ApproxFunBase/Jv4NR/src/Spaces/SumSpace.jl:35
   [6] default_Fun(::ApproxFunBase.DFunction, ::ApproxFunBase.SumSpace{Tuple{CosSpace{PeriodicSegment{Float64},Float64},SinSpace{PeriodicSegment{Float64},Float64}},PeriodicSegment{Float64},Float64}) at /home/pkgeval/.julia/packages/ApproxFunBase/Jv4NR/src/constructors.jl:127
   [7] Fun(::Function, ::ApproxFunBase.SumSpace{Tuple{CosSpace{PeriodicSegment{Float64},Float64},SinSpace{PeriodicSegment{Float64},Float64}},PeriodicSegment{Float64},Float64}) at /home/pkgeval/.julia/packages/ApproxFunBase/Jv4NR/src/constructors.jl:177
   [8] top-level scope at /home/pkgeval/.julia/packages/ApproxFun/IC3js/test/ReadmeTest.jl:76
   [9] top-level scope at /workspace/srcdir/usr/share/julia/stdlib/v1.5/Test/src/Test.jl:1114
   [10] top-level scope at /home/pkgeval/.julia/packages/ApproxFun/IC3js/test/ReadmeTest.jl:76
   [11] top-level scope at /workspace/srcdir/usr/share/julia/stdlib/v1.5/Test/src/Test.jl:1114
   [12] top-level scope at /home/pkgeval/.julia/packages/ApproxFun/IC3js/test/ReadmeTest.jl:5
   [13] include(::String) at ./client.jl:457
   [14] top-level scope at ./timing.jl:174 [inlined]
   [15] top-level scope at /home/pkgeval/.julia/packages/ApproxFun/IC3js/test/runtests.jl:0
   [16] include(::String) at ./client.jl:457
   [17] top-level scope at none:6
   [18] eval(::Module, ::Any) at ./boot.jl:331
   [19] exec_options(::Base.JLOptions) at ./client.jl:272
   [20] _start() at ./client.jl:506

to permit e.g. findfirst(>(5), 1:InfiniteArrays.Infinity()) to work

simeonschaub pushed a commit to simeonschaub/julia that referenced this pull request Aug 11, 2020
- restore some `copyto!` methods that Knet assumed existed
- allow `findfirst` to work on InfiniteArrays again
- allow constructing a LineNumberNode from a String
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

Successfully merging this pull request may close these issues.

4 participants