You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This commit addresses bugs introduce after minification (and
mangling). Because the function references occur in evaluated
strings, several bugs can be encountered. For example, the
minification engine may decide to eliminate what it considers
unused code/variables. Next, a minification engine may rename the
variables, thus introducing a discrepancy in the evaluated string
which relies on the source variable names. The workaround used in
this commit is to bind the functions directly to the evaluated
function, where property names are less likely to be mangled.
* > if ( !isInteger( i0 ) ) { throw new TypeError( ... ) }
66
66
*/
67
67
for(i=0;i<ndims;i++){
68
-
f+='if(!isInteger(i'+i+')){throw new TypeError(\'invalid input argument. Indices must be integer valued. Argument: '+i+'. Value: `\'+i'+i+'+\'`.\');}';
68
+
f+='if(!f.__isint__(i'+i+')){throw new TypeError(\'invalid input argument. Indices must be integer valued. Argument: '+i+'. Value: `\'+i'+i+'+\'`.\');}';
* > if ( !isInteger( i0 ) ) { throw new TypeError( ... ) }
63
63
*/
64
64
for(i=0;i<ndims;i++){
65
-
f+='if(!isInteger(i'+i+')){throw new TypeError(\'invalid input argument. Indices must be integer valued. Argument: '+i+'. Value: `\'+i'+i+'+\'`.\');}';
65
+
f+='if(!f.__isint__(i'+i+')){throw new TypeError(\'invalid input argument. Indices must be integer valued. Argument: '+i+'. Value: `\'+i'+i+'+\'`.\');}';
0 commit comments