|
@@ -26723,13 +26723,13 @@ $core.method({
|
|
selector: "version",
|
|
selector: "version",
|
|
protocol: "accessing",
|
|
protocol: "accessing",
|
|
args: [],
|
|
args: [],
|
|
-source: "version\x0a\x09\x22Answer the version string of Amber\x22\x0a\x09\x0a\x09^ '0.28.0'",
|
|
|
|
|
|
+source: "version\x0a\x09\x22Answer the version string of Amber\x22\x0a\x09\x0a\x09^ '0.28.1'",
|
|
referencedClasses: [],
|
|
referencedClasses: [],
|
|
pragmas: [],
|
|
pragmas: [],
|
|
messageSends: []
|
|
messageSends: []
|
|
}, function ($methodClass){ return function (){
|
|
}, function ($methodClass){ return function (){
|
|
var self=this,$self=this;
|
|
var self=this,$self=this;
|
|
-return "0.28.0";
|
|
|
|
|
|
+return "0.28.1";
|
|
|
|
|
|
}; }),
|
|
}; }),
|
|
$globals.SmalltalkImage);
|
|
$globals.SmalltalkImage);
|
|
@@ -43047,13 +43047,22 @@ $core.method({
|
|
selector: "isVariableKnown:inPackage:",
|
|
selector: "isVariableKnown:inPackage:",
|
|
protocol: "testing",
|
|
protocol: "testing",
|
|
args: ["aString", "aPackage"],
|
|
args: ["aString", "aPackage"],
|
|
-source: "isVariableKnown: aString inPackage: aPackage\x0a\x09^ Compiler new\x0a\x09\x09eval: 'typeof(', aString, ')!== \x22undefined\x22||(function(){try{return(', aString, ',true)}catch(_){return false}})()'\x0a\x09\x09forPackage: aPackage",
|
|
|
|
|
|
+source: "isVariableKnown: aString inPackage: aPackage\x0a\x09aPackage ifNotNil: [\x0a\x09\x09| packageKnownVars |\x0a\x09\x09packageKnownVars := (aPackage imports reject: #isString) collect: #key.\x0a\x09\x09(packageKnownVars includes: aString) ifTrue: [ ^ true ] ].\x0a\x09^ Compiler new\x0a\x09\x09eval: 'typeof(', aString, ')!== \x22undefined\x22||(function(){try{return(', aString, ',true)}catch(_){return false}})()'\x0a\x09\x09forPackage: aPackage",
|
|
referencedClasses: ["Compiler"],
|
|
referencedClasses: ["Compiler"],
|
|
pragmas: [],
|
|
pragmas: [],
|
|
-messageSends: ["eval:forPackage:", "new", ","]
|
|
|
|
|
|
+messageSends: ["ifNotNil:", "collect:", "reject:", "imports", "ifTrue:", "includes:", "eval:forPackage:", "new", ","]
|
|
}, function ($methodClass){ return function (aString,aPackage){
|
|
}, function ($methodClass){ return function (aString,aPackage){
|
|
var self=this,$self=this;
|
|
var self=this,$self=this;
|
|
return $core.withContext(function($ctx1) {
|
|
return $core.withContext(function($ctx1) {
|
|
|
|
+if(aPackage == null || aPackage.a$nil){
|
|
|
|
+aPackage;
|
|
|
|
+} else {
|
|
|
|
+var packageKnownVars;
|
|
|
|
+packageKnownVars=$recv($recv($recv(aPackage)._imports())._reject_("isString"))._collect_("key");
|
|
|
|
+if($core.assert($recv(packageKnownVars)._includes_(aString))){
|
|
|
|
+return true;
|
|
|
|
+}
|
|
|
|
+}
|
|
return $recv($recv($globals.Compiler)._new())._eval_forPackage_([$recv([$recv([$recv("typeof(".__comma(aString)).__comma(")!== \x22undefined\x22||(function(){try{return(")
|
|
return $recv($recv($globals.Compiler)._new())._eval_forPackage_([$recv([$recv([$recv("typeof(".__comma(aString)).__comma(")!== \x22undefined\x22||(function(){try{return(")
|
|
,$ctx1.sendIdx[","]=3
|
|
,$ctx1.sendIdx[","]=3
|
|
][0]).__comma(aString)
|
|
][0]).__comma(aString)
|