Closed abelsiqueira closed 7 years ago
This fails on 0.4 because I use the generator syntax. It's the only way to make it work with CUTEst because we can't open more than one problem at the same time.
The generator expression syntax (...)
wasn't available in Julia 0.4, but we could still implement a generator as follows:
function cutest_problems(names :: Vector{ASCIIString}) # names must be an array but that's ok
function my_iterator()
for name in names
produce(CUTEstModel(name)) # like yield in Python
end
end
return Task(my_iterator)
end
# Example usage:
function work_through_stuff(stuff)
for thing in stuff
println(thing)
end
end
work_through_stuff(cutest_problems(["rosenbrock", "hs13", "ncvxqp3"]))
The question is: should we continue to support Julia 0.4?
I see, wasn't aware of that way to do it. But I think we should drop 0.4. NLPModels already dropped, and CUTEst will follow.
Ok.
MacroTools.jl 0.3.5 is breaking this (and everything inbetween).
Coverage increased (+0.1%) to 68.707% when pulling 1038500fb9eabdea73ffa33cc0ef2d41bd7d9dbc on abelsiqueira:fix/bmark-solvers-finalize into 30dac885fc5f7096d45011758c3d52dbe2e7df68 on JuliaSmoothOptimizers:master.