Code coverage report for sc/lang/compiler/codegen/envir-expr.js

Statements: 100% (8 / 8)      Branches: 100% (2 / 2)      Functions: 100% (2 / 2)      Lines: 100% (8 / 8)      Ignored: none     

All files » sc/lang/compiler/codegen/ » envir-expr.js
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 191     1   1   1 5   3       2 2      
(function(sc) {
  "use strict";
 
  require("./codegen");
 
  var CodeGen = sc.lang.compiler.CodeGen;
 
  CodeGen.addGenerateMethod("EnvironmentExpression", function(node, opts) {
    if (!opts) {
      // getter
      return "$.Environment('" + node.id.name + "')";
    }
 
    // setter
    opts.used = true;
    return [ "$.Environment('" + node.id.name + "',", this.generate(opts.right), ")" ];
  });
})(sc);