The document discusses developing a programming language called Prattle. It provides examples of the language's syntax for elements like self, true, false, nil, numbers, strings, unary sends, keyword sends, blocks, and operators. It also describes running code in Prattle using a REPL and compiling Prattle code to Ruby bytecode.
75. Keyword Send
ks = atom (pair ‘ ‘)+
pair
Tuesday, February 8, 2011
76. Keyword Send
def bytecode(g)
@receiver.bytecode(g)
@arguments.each do |a|
a.bytecode(a)
end
g.send @method_name.to_sym,
@arguments.size
end
Tuesday, February 8, 2011
77. Keyword Send
def bytecode(g)
@receiver.bytecode(g)
@arguments.each do |a|
a.bytecode(a)
end
g.send @method_name.to_sym,
@arguments.size
end
Tuesday, February 8, 2011