diff options
author | Sunil Shetye | 2018-07-11 13:05:13 +0530 |
---|---|---|
committer | Sunil Shetye | 2018-07-11 15:21:08 +0530 |
commit | 079d0b4a3ec15a4d7d2644484d116df9d1c694bb (patch) | |
tree | 785ed59b5b238203a9e91f3e323da59d1083d86e /js/Branching/GOTOMO.js | |
parent | 0e9bc36f45fa1bb598c6ebb0febc1989439a8d98 (diff) | |
download | sci2js-079d0b4a3ec15a4d7d2644484d116df9d1c694bb.tar.gz sci2js-079d0b4a3ec15a4d7d2644484d116df9d1c694bb.tar.bz2 sci2js-079d0b4a3ec15a4d7d2644484d116df9d1c694bb.zip |
fix assignment to list
Diffstat (limited to 'js/Branching/GOTOMO.js')
-rw-r--r-- | js/Branching/GOTOMO.js | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/js/Branching/GOTOMO.js b/js/Branching/GOTOMO.js index 81683fcd..473bfd8c 100644 --- a/js/Branching/GOTOMO.js +++ b/js/Branching/GOTOMO.js @@ -13,11 +13,11 @@ function GOTOMO() { this.model.opar = list(new ScilabString(["A"])); this.model.blocktype = new ScilabString(["c"]); this.model.dep_ut = [false,false]; - mo = modelica(); + var mo = modelica(); mo.model = "gotomo"; mo.inputs = "p"; - exprs = [["A"],[sci2exp(1)]]; - gr_i = []; + var exprs = [["A"],[sci2exp(1)]]; + var gr_i = []; this.x = standard_define([2,1],this.model,exprs,gr_i); this.x.graphics.in_implicit = ["I"]; return new BasicBlock(this.x); @@ -36,8 +36,8 @@ function GOTOMO() { this.tag = arguments[0]["tag"] this.tagvis = parseFloat(arguments[0]["tagvis"]) this.x = arg1; - graphics = arg1.graphics; - exprs = graphics.exprs; + var graphics = arg1.graphics; + var exprs = graphics.exprs; this.model = arg1.model; while (true) { [ok,this.tag,this.tagvis,exprs] = scicos_getvalue("Set parameters",["Tag","Tag Visibility(1=Local 2=scoped 3= global)"],list("str",-1,"vec",1),exprs); @@ -47,19 +47,19 @@ function GOTOMO() { this.tagvis = int(this.tagvis); if (((this.tagvis<1)||(this.tagvis>3))) { message("Tag Visibility must be between 1 and 3"); - ok = false; + var ok = false; } if (ok) { if (((this.model.ipar!=this.tagvis)||(this.model.opar!=list(this.tag)))) { - needcompile = 4; - y = needcompile; + var needcompile = 4; + var y = needcompile; } graphics.exprs = exprs; this.model.opar = list(new ScilabDouble([this.tag])); this.model.ipar = new ScilabDouble([this.tagvis]); this.x.model = this.model; this.x.graphics = graphics; - arg1 = this.x; + var arg1 = this.x; break; } } |