comparison samples/reflect.tp @ 268:123e9468d55e

Add support for invoking methods that take no arguments other than self through the relfection API
author Michael Pavone <pavone@retrodev.com>
date Fri, 18 Jul 2014 09:55:19 -0700
parents 75dc7161c1ca
children b74956a2196f
comparison
equal deleted inserted replaced
267:d2b70cba661e 268:123e9468d55e
3 print: (string: (object does: 42 understand?: "+")) . "\n" 3 print: (string: (object does: 42 understand?: "+")) . "\n"
4 print: (string: (object does: 42 understand?: "foobar")) . "\n" 4 print: (string: (object does: 42 understand?: "foobar")) . "\n"
5 foreach: (object understoodBy: 42) :idx el{ 5 foreach: (object understoodBy: 42) :idx el{
6 print: el . "\n" 6 print: el . "\n"
7 } 7 }
8 print: (object sendMessage: "hex" to: 42) . "\n"
8 0 9 0
9 } 10 }
10 } 11 }