File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change 606
606
607
607
function collect_var! (unknowns, parameters, var, iv; depth = 0 )
608
608
isequal (var, iv) && return nothing
609
+ if Symbolics. iswrapped (var)
610
+ error ("""
611
+ Internal Error. Please open an issue with an MWE.
612
+
613
+ Encountered a wrapped value in `collect_var!`. This function should only ever \
614
+ receive unwrapped symbolic variables. This is likely a bug in the code generating \
615
+ an expression passed to `collect_vars!` or `collect_scoped_vars!`. A common cause \
616
+ is using `substitute` or `fast_substitute` with rules where the values are \
617
+ wrapped symbolic variables.
618
+ """ )
619
+ end
609
620
check_scope_depth (getmetadata (var, SymScope, LocalScope ()), depth) || return nothing
610
621
var = setmetadata (var, SymScope, LocalScope ())
611
622
if iscalledparameter (var)
You can’t perform that action at this time.
0 commit comments