Should I be concerned by the many Any
s? Or is there something specific to look for regarding the type stability issue and multi-threading?
Variables
#self#::Core.Const(JuMP.var"@variable")
__source__::LineNumberNode
__module__::Module
args@_4::Tuple{Symbol, Expr, Symbol}
@_5::Int64
#107::JuMP.var"#107#116"
@_7::Any
#106::JuMP.var"#106#115"
#105::JuMP.var"#105#114"
#104::JuMP.var"#104#113"
@_11::Int64
#103::JuMP.var"#103#112"
#102::JuMP.var"#102#111"
#101::JuMP.var"#101#110"
#100::JuMP.var"#100#109"
@_16::Int64
macro_code::Expr
creation_code::Expr
variablecall::Expr
buildcall::Expr
scalar_variables::Expr
name_code::Any
indices::Expr
idxvars::Vector{Any}
info::Expr
extra::Any
set::Any
base_name::Any
name::Any
variable::Symbol
anonvar::Bool
var::Any
explicit_comparison::Bool
infoexpr::JuMP._VariableInfoExpr
set_kw_args::Any
variable_type_kw_args::Any
base_name_kw_args::Any
extra_kw_args::Any
info_kw_args::Any
anon_singleton::Bool
x::Any
requestedcontainer::Any
kw_args::Any
model::Expr
_error::JuMP.var"#_error#108"{LineNumberNode}
ex::Any
args@_47::Union{}
args@_48::Union{}
args@_49::Union{}
args@_50::Union{}
args@_51::Union{}
args@_52::Union{}
args@_53::Union{Core.Box, Tuple{Symbol, Expr, Symbol}}
@_54::JuMP._VariableInfoExpr
@_55::Bool
@_56::Bool
@_57::Bool
@_58::Any
@_59::Bool
Body::Expr
1 βββ (args@_53 = args@_4)
β (args@_53 = Core.Box(args@_53::Tuple{Symbol, Expr, Symbol}))
β Core.NewvarNode(:(@_5))
β Core.NewvarNode(:(#107))
β Core.NewvarNode(:(@_7))
β Core.NewvarNode(:(#106))
β Core.NewvarNode(:(#105))
β Core.NewvarNode(:(#104))
β Core.NewvarNode(:(@_11))
β Core.NewvarNode(:(#103))
β Core.NewvarNode(:(#102))
β Core.NewvarNode(:(#101))
β Core.NewvarNode(:(#100))
β Core.NewvarNode(:(@_16))
β Core.NewvarNode(:(macro_code))
β Core.NewvarNode(:(creation_code))
β Core.NewvarNode(:(variablecall))
β Core.NewvarNode(:(buildcall))
β Core.NewvarNode(:(scalar_variables))
β Core.NewvarNode(:(name_code))
β Core.NewvarNode(:(indices))
β Core.NewvarNode(:(idxvars))
β Core.NewvarNode(:(info))
β Core.NewvarNode(:(extra))
β Core.NewvarNode(:(set))
β Core.NewvarNode(:(base_name))
β Core.NewvarNode(:(name))
β Core.NewvarNode(:(variable))
β Core.NewvarNode(:(anonvar))
β Core.NewvarNode(:(var))
β Core.NewvarNode(:(explicit_comparison))
β Core.NewvarNode(:(infoexpr))
β Core.NewvarNode(:(set_kw_args))
β Core.NewvarNode(:(variable_type_kw_args))
β Core.NewvarNode(:(base_name_kw_args))
β Core.NewvarNode(:(extra_kw_args))
β Core.NewvarNode(:(info_kw_args))
β Core.NewvarNode(:(anon_singleton))
β Core.NewvarNode(:(x))
β Core.NewvarNode(:(requestedcontainer))
β Core.NewvarNode(:(kw_args))
β Core.NewvarNode(:(model))
β %43 = JuMP.:(var"#_error#108")::Core.Const(JuMP.var"#_error#108")
β %44 = Core.typeof(__source__)::Core.Const(LineNumberNode)
β %45 = Core.apply_type(%43, %44)::Core.Const(JuMP.var"#_error#108"{LineNumberNode})
β (_error = %new(%45, __source__, args@_53::Core.Box))
β %47 = Core.isdefined(args@_53::Core.Box, :contents)::Bool
βββββ goto #3 if not %47
2 βββ goto #4
3 βββ Core.NewvarNode(:(args@_47))
βββββ args@_47
4 βββ %52 = Core.getfield(args@_53::Core.Box, :contents)::Any
β %53 = JuMP._reorder_parameters(%52)::Any
β Core.setfield!(args@_53::Core.Box, :contents, %53)
β %55 = Core.isdefined(args@_53::Core.Box, :contents)::Bool
βββββ goto #6 if not %55
5 βββ goto #7
6 βββ Core.NewvarNode(:(args@_48))
βββββ args@_48
7 βββ %60 = Core.getfield(args@_53::Core.Box, :contents)::Any
β %61 = Base.getindex(%60, 1)::Any
β (model = JuMP.esc(%61))
β %63 = JuMP.Containers._extract_kw_args::Core.Const(JuMP.Containers._extract_kw_args)
β %64 = Core.isdefined(args@_53::Core.Box, :contents)::Bool
βββββ goto #9 if not %64
8 βββ goto #10
9 βββ Core.NewvarNode(:(args@_49))
βββββ args@_49
10 ββ %69 = Core.getfield(args@_53::Core.Box, :contents)::Any
β %70 = Core.isdefined(args@_53::Core.Box, :contents)::Bool
βββββ goto #12 if not %70
11 ββ goto #13
12 ββ Core.NewvarNode(:(args@_50))
βββββ args@_50
13 ββ %75 = Core.getfield(args@_53::Core.Box, :contents)::Any
β %76 = Base.lastindex(%75)::Any
β %77 = (2:%76)::Any
β %78 = Base.getindex(%69, %77)::Any
β %79 = (%63)(%78)::Tuple{Any, Any, Any}
β %80 = Base.indexed_iterate(%79, 1)::Core.PartialStruct(Tuple{Any, Int64}, Any[Any, Core.Const(2)])
β (extra = Core.getfield(%80, 1))
β (@_16 = Core.getfield(%80, 2))
β %83 = Base.indexed_iterate(%79, 2, @_16::Core.Const(2))::Core.PartialStruct(Tuple{Any, Int64}, Any[Any, Core.Const(3)])
β (kw_args = Core.getfield(%83, 1))
β (@_16 = Core.getfield(%83, 2))
β %86 = Base.indexed_iterate(%79, 3, @_16::Core.Const(3))::Core.PartialStruct(Tuple{Any, Int64}, Any[Any, Core.Const(4)])
β (requestedcontainer = Core.getfield(%86, 1))
β %88 = JuMP.length(extra)::Any
β %89 = (%88 == 0)::Any
βββββ goto #15 if not %89
14 ββ (x = JuMP.gensym())
β (anon_singleton = true)
βββββ goto #22
15 ββ (x = JuMP.popfirst!(extra))
β %95 = (x == :Int)::Union{Missing, Bool}
βββββ goto #17 if not %95
16 ββ %97 = Base.string("Ambiguous variable name ", x, " detected. To specify an anonymous integer ")::String
β %98 = (%97 * "variable, use `@variable(model, integer = true)` instead.")::String
β (_error)(%98)
βββββ Core.Const(:(goto %111))
17 ββ %101 = (x == :Bin)::Union{Missing, Bool}
βββββ goto #19 if not %101
18 ββ %103 = Base.string("Ambiguous variable name ", x, " detected. To specify an anonymous binary ")::String
β %104 = (%103 * "variable, use `@variable(model, binary = true)` instead.")::String
β (_error)(%104)
βββββ Core.Const(:(goto %111))
19 ββ %107 = (x == :PSD)::Union{Missing, Bool}
βββββ goto #21 if not %107
20 ββ %109 = ("Size of anonymous square matrix of positive semidefinite anonymous variables is not specified. To specify size of square matrix " * "use `@variable(model, [1:n, 1:n], PSD)` instead.")::String
βββββ (_error)(%109)
21 ββ (anon_singleton = false)
22 ββ (info_kw_args = JuMP.filter(JuMP._is_info_keyword, kw_args))
β (#100 = %new(JuMP.:(var"#100#109")))
β %114 = #100::Core.Const(JuMP.var"#100#109"())
β (extra_kw_args = JuMP.filter(%114, kw_args))
β (#101 = %new(JuMP.:(var"#101#110")))
β %117 = #101::Core.Const(JuMP.var"#101#110"())
β (base_name_kw_args = JuMP.filter(%117, kw_args))
β (#102 = %new(JuMP.:(var"#102#111")))
β %120 = #102::Core.Const(JuMP.var"#102#111"())
β (variable_type_kw_args = JuMP.filter(%120, kw_args))
β (#103 = %new(JuMP.:(var"#103#112")))
β %123 = #103::Core.Const(JuMP.var"#103#112"())
β (set_kw_args = JuMP.filter(%123, kw_args))
β %125 = Base.NamedTuple()::Core.Const(NamedTuple())
β %126 = Base.broadcasted(JuMP._keywordify, info_kw_args)::Any
β %127 = Base.materialize(%126)::Any
β %128 = Base.merge(%125, %127)::Any
β %129 = Base.isempty(%128)::Any
βββββ goto #24 if not %129
23 ββ (@_54 = JuMP._VariableInfoExpr())
βββββ goto #25
24 ββ %133 = Core.kwfunc(JuMP._VariableInfoExpr)::Core.Const(Core.var"#Type##kw"())
βββββ (@_54 = (%133)(%128, JuMP._VariableInfoExpr))
25 ββ (infoexpr = @_54)
β %136 = JuMP.isexpr(x, :comparison)::Bool
βββββ goto #27 if not %136
26 ββ (@_55 = %136)
βββββ goto #28
27 ββ (@_55 = JuMP.isexpr(x, :call))
28 ββ (explicit_comparison = @_55)
βββββ goto #30 if not explicit_comparison
29 ββ %143 = Core.tuple(_error, infoexpr)::Tuple{JuMP.var"#_error#108"{LineNumberNode}, JuMP._VariableInfoExpr}
β %144 = Base.getproperty(x, :args)::Any
β %145 = Core._apply_iterate(Base.iterate, JuMP.parse_variable, %143, %144)::Tuple{Any, Any}
β %146 = Base.indexed_iterate(%145, 1)::Core.PartialStruct(Tuple{Any, Int64}, Any[Any, Core.Const(2)])
β (var = Core.getfield(%146, 1))
β (@_11 = Core.getfield(%146, 2))
β %149 = Base.indexed_iterate(%145, 2, @_11::Core.Const(2))::Core.PartialStruct(Tuple{Any, Int64}, Any[Any, Core.Const(3)])
β (set = Core.getfield(%149, 1))
βββββ goto #31
30 ββ (var = x)
βββββ (set = JuMP.nothing)
31 ββ %154 = JuMP.isexpr(var, :vect)::Bool
βββββ goto #33 if not %154
32 ββ (@_56 = %154)
βββββ goto #37
33 ββ %158 = JuMP.isexpr(var, :vcat)::Bool
βββββ goto #35 if not %158
34 ββ (@_57 = %158)
βββββ goto #36
35 ββ (@_57 = anon_singleton)
36 ββ (@_56 = @_57)
37 ββ (anonvar = @_56)
βββββ goto #41 if not anonvar
38 ββ goto #41 if not explicit_comparison
39 ββ %167 = (set === JuMP.nothing)::Bool
βββββ goto #41 if not %167
40 ββ (_error)("Cannot use explicit bounds via >=, <= with an anonymous variable")
41 ββ (variable = JuMP.gensym())
β %171 = JuMP.Containers._get_name::Core.Const(JuMP.Containers._get_name)
β (name = (%171)(var))
β %173 = JuMP.isempty(base_name_kw_args)::Any
βββββ goto #46 if not %173
42 ββ goto #44 if not anonvar
43 ββ (@_58 = "")
βββββ goto #45
44 ββ (@_58 = JuMP.string(name))
45 ββ (base_name = @_58)
βββββ goto #47
46 ββ %181 = Base.getindex(base_name_kw_args, 1)::Any
β %182 = Base.getproperty(%181, :args)::Any
β %183 = Base.getindex(%182, 2)::Any
βββββ (base_name = JuMP.esc(%183))
47 ββ %185 = (name isa JuMP.Symbol)::Bool
β %186 = !%185::Bool
βββββ goto #50 if not %186
48 ββ %188 = !anonvar::Bool
βββββ goto #50 if not %188
49 ββ %190 = Base.error::Core.Const(error)
β %191 = Base.string("Expression ", name, " should not be used as a variable name. Use the \"anonymous\" syntax ", name, " = @variable(model, ...) instead.")::String
βββββ (%190)(%191)
50 ββ %193 = JuMP.isempty(set_kw_args)::Any
β %194 = !%193::Any
βββββ goto #56 if not %194
51 ββ %196 = JuMP.length(set_kw_args)::Any
β %197 = (%196 > 1)::Any
βββββ goto #53 if not %197
52 ββ %199 = JuMP.length(set_kw_args)::Any
β %200 = Base.string("`set` keyword argument was given ", %199, " times.")::String
βββββ (_error)(%200)
53 ββ %202 = (set !== JuMP.nothing)::Bool
βββββ goto #55 if not %202
54 ββ %204 = Base.string("Cannot specify set twice, it was already set to `", set, "` so the `set` keyword argument is not allowed.")::String
βββββ (_error)(%204)
55 ββ %206 = Base.getindex(set_kw_args, 1)::Any
β %207 = Base.getproperty(%206, :args)::Any
β %208 = Base.getindex(%207, 2)::Any
βββββ (set = JuMP.esc(%208))
56 ββ (#104 = %new(JuMP.:(var"#104#113")))
β %211 = #104::Core.Const(JuMP.var"#104#113"())
β %212 = JuMP.any(%211, extra)::Any
βββββ goto #60 if not %212
57 ββ %214 = (set !== JuMP.nothing)::Bool
βββββ goto #59 if not %214
58 ββ %216 = Base.string("Cannot specify set twice, it was already set to `", set, "` so the `PSD` argument is not allowed.")::String
βββββ (_error)(%216)
59 ββ (set = $(Expr(:copyast, :($(QuoteNode(:(JuMP.PSDCone())))))))
60 ββ (#105 = %new(JuMP.:(var"#105#114")))
β %220 = #105::Core.Const(JuMP.var"#105#114"())
β %221 = JuMP.any(%220, extra)::Any
βββββ goto #64 if not %221
61 ββ %223 = (set !== JuMP.nothing)::Bool
βββββ goto #63 if not %223
62 ββ %225 = Base.string("Cannot specify `Symmetric` when the set is already specified, the variable is constrained to belong to `", set, "`.")::String
βββββ (_error)(%225)
63 ββ (set = $(Expr(:copyast, :($(QuoteNode(:(JuMP.SymMatrixSpace())))))))
64 ββ (#106 = %new(JuMP.:(var"#106#115")))
β %229 = #106::Core.Const(JuMP.var"#106#115"())
β (extra = JuMP.filter(%229, extra))
β %231 = extra::Any
β (@_7 = Base.iterate(%231))
β %233 = (@_7 === nothing)::Bool
β %234 = Base.not_int(%233)::Bool
βββββ goto #71 if not %234
65 ββ %236 = @_7::Any
β (ex = Core.getfield(%236, 1))
β %238 = Core.getfield(%236, 2)::Any
β %239 = (ex == :Int)::Union{Missing, Bool}
βββββ goto #67 if not %239
66 ββ JuMP._set_integer_or_error(_error, infoexpr)
βββββ goto #69
67 ββ %243 = (ex == :Bin)::Union{Missing, Bool}
βββββ goto #69 if not %243
68 ββ JuMP._set_binary_or_error(_error, infoexpr)
69 ββ (@_7 = Base.iterate(%231, %238))
β %247 = (@_7 === nothing)::Bool
β %248 = Base.not_int(%247)::Bool
βββββ goto #71 if not %248
70 ββ goto #65
71 ββ (#107 = %new(JuMP.:(var"#107#116")))
β %252 = #107::Core.Const(JuMP.var"#107#116"())
β %253 = JuMP.filter(%252, extra)::Any
β %254 = Base.broadcasted(JuMP.esc, %253)::Any
β (extra = Base.materialize(%254))
β %256 = JuMP.isempty(variable_type_kw_args)::Any
β %257 = !%256::Any
βββββ goto #73 if not %257
72 ββ %259 = extra::Any
β %260 = Base.getindex(variable_type_kw_args, 1)::Any
β %261 = Base.getproperty(%260, :args)::Any
β %262 = Base.getindex(%261, 2)::Any
β %263 = JuMP.esc(%262)::Expr
βββββ JuMP.push!(%259, %263)
73 ββ (info = JuMP._constructor_expr(infoexpr))
β %266 = (var isa JuMP.Symbol)::Bool
βββββ goto #75 if not %266
74 ββ (name_code = base_name)
βββββ goto #88
75 ββ %270 = (var isa JuMP.Expr)::Bool
βββββ goto #77 if not %270
76 ββ goto #78
77 ββ %273 = Base.string("Expected ", var, " to be a variable name")::String
βββββ (_error)(%273)
78 ββ %275 = JuMP.Containers._build_ref_sets::Core.Const(JuMP.Containers._build_ref_sets)
β %276 = _error::JuMP.var"#_error#108"{LineNumberNode}
β %277 = (%275)(%276, var::Expr)::Tuple{Vector{Any}, Expr}
β %278 = Base.indexed_iterate(%277, 1)::Core.PartialStruct(Tuple{Vector{Any}, Int64}, Any[Vector{Any}, Core.Const(2)])
β (idxvars = Core.getfield(%278, 1))
β (@_5 = Core.getfield(%278, 2))
β %281 = Base.indexed_iterate(%277, 2, @_5::Core.Const(2))::Core.PartialStruct(Tuple{Expr, Int64}, Any[Expr, Core.Const(3)])
β (indices = Core.getfield(%281, 1))
β %283 = Core.isdefined(args@_53::Core.Box, :contents)::Bool
βββββ goto #80 if not %283
79 ββ goto #81
80 ββ Core.NewvarNode(:(args@_51))
βββββ args@_51
81 ββ %288 = Core.getfield(args@_53::Core.Box, :contents)::Any
β %289 = Base.getindex(%288, 1)::Any
β %290 = (%289 in idxvars)::Union{Missing, Bool}
βββββ goto #86 if not %290
82 ββ %292 = Core.isdefined(args@_53::Core.Box, :contents)::Bool
βββββ goto #84 if not %292
83 ββ goto #85
84 ββ Core.NewvarNode(:(args@_52))
βββββ args@_52
85 ββ %297 = Core.getfield(args@_53::Core.Box, :contents)::Any
β %298 = Base.getindex(%297, 1)::Any
β %299 = Base.string("Index ", %298, " is the same symbol as the model. Use a ")::String
β %300 = (%299 * "different name for the index.")::String
βββββ (_error)(%300)
86 ββ (name_code = JuMP._name_call(base_name, idxvars))
β %303 = (set !== JuMP.nothing)::Bool
βββββ goto #88 if not %303
87 ββ %305 = JuMP.Containers.container_code::Core.Const(JuMP.Containers.container_code)
β %306 = idxvars::Vector{Any}
β %307 = indices::Expr
β %308 = name_code::Any
βββββ (name_code = (%305)(%306, %307, %308, requestedcontainer))
88 ββ %310 = Core.tuple(:call, :build_variable, _error, info)::Core.PartialStruct(Tuple{Symbol, Symbol, JuMP.var"#_error#108"{LineNumberNode}, Expr}, Any[Core.Const(:call), Core.Const(:build_variable), JuMP.var"#_error#108"{LineNumberNode}, Expr])
β (buildcall = Core._apply_iterate(Base.iterate, Core._expr, %310, extra))
β JuMP._add_kw_args(buildcall, extra_kw_args)
β %313 = (set !== JuMP.nothing)::Bool
βββββ goto #93 if not %313
89 ββ %315 = (var::Union{Expr, Symbol} isa JuMP.Symbol)::Bool
βββββ goto #91 if not %315
90 ββ (scalar_variables = buildcall)
βββββ goto #92
91 ββ %319 = JuMP.Containers.container_code::Core.Const(JuMP.Containers.container_code)
β %320 = idxvars::Vector{Any}
β %321 = indices::Expr
β %322 = buildcall::Expr
βββββ (scalar_variables = (%319)(%320, %321, %322, requestedcontainer))
92 ββ (buildcall = Core._expr(:call, :build_variable, _error, scalar_variables, set))
93 ββ (variablecall = Core._expr(:call, :add_variable, model, buildcall, name_code))
β %326 = (var::Union{Expr, Symbol} isa JuMP.Symbol)::Bool
βββββ goto #95 if not %326
94 ββ (@_59 = %326)
βββββ goto #96
95 ββ (@_59 = set !== JuMP.nothing)
96 ββ goto #98 if not @_59
97 ββ (creation_code = variablecall)
βββββ goto #99
98 ββ %334 = JuMP.Containers.container_code::Core.Const(JuMP.Containers.container_code)
β %335 = idxvars::Vector{Any}
β %336 = indices::Expr
β %337 = variablecall::Expr
βββββ (creation_code = (%334)(%335, %336, %337, requestedcontainer))
99 ββ goto #101 if not anonvar
100 β (macro_code = creation_code)
βββββ goto #102
101 β %342 = (:model_for_registering,)::Core.Const((:model_for_registering,))
β %343 = Core.apply_type(Core.NamedTuple, %342)::Core.Const(NamedTuple{(:model_for_registering,), T} where T<:Tuple)
β %344 = Core.tuple(model)::Tuple{Expr}
β %345 = (%343)(%344)::NamedTuple{(:model_for_registering,), Tuple{Expr}}
β %346 = Core.kwfunc(JuMP._macro_assign_and_return)::Core.Const(JuMP.var"#_macro_assign_and_return##kw"())
β %347 = creation_code::Expr
β %348 = variable::Symbol
βββββ (macro_code = (%346)(%345, JuMP._macro_assign_and_return, %347, %348, name))
102 β %350 = JuMP._finalize_macro(model, macro_code, __source__)::Expr
βββββ return %350