Browse Source

subclassResponsibility

Herbert Vojčík 12 years ago
parent
commit
f1f20af820
3 changed files with 31 additions and 0 deletions
  1. 11 0
      js/Compiler.deploy.js
  2. 16 0
      js/Compiler.js
  3. 4 0
      st/Compiler.st

+ 11 - 0
js/Compiler.deploy.js

@@ -1234,6 +1234,17 @@ return self;}
 }),
 smalltalk.AbstractCompiler);
 
+smalltalk.addMethod(
+"_compileNode_",
+smalltalk.method({
+selector: "compileNode:",
+fn: function (aNode) {
+var self=this;
+smalltalk.send(self, "_subclassResponsibility", []);
+return self;}
+}),
+smalltalk.AbstractCompiler);
+
 smalltalk.addMethod(
 "_currentClass",
 smalltalk.method({

+ 16 - 0
js/Compiler.js

@@ -1744,6 +1744,22 @@ referencedClasses: ["DoIt"]
 }),
 smalltalk.AbstractCompiler);
 
+smalltalk.addMethod(
+"_compileNode_",
+smalltalk.method({
+selector: "compileNode:",
+category: 'compiling',
+fn: function (aNode) {
+var self=this;
+smalltalk.send(self, "_subclassResponsibility", []);
+return self;},
+args: ["aNode"],
+source: "compileNode: aNode\x0a\x09self subclassResponsibility",
+messageSends: ["subclassResponsibility"],
+referencedClasses: []
+}),
+smalltalk.AbstractCompiler);
+
 smalltalk.addMethod(
 "_currentClass",
 smalltalk.method({

+ 4 - 0
st/Compiler.st

@@ -841,6 +841,10 @@ compileExpression: aString
 	^self compileNode: (self parse: self source)
 !
 
+compileNode: aNode
+	self subclassResponsibility
+!
+
 eval: aString
 	<return eval(aString)>
 !