Mercurial > repos > tabletprog
annotate samples/hash.tp @ 84:9811040704ac
Add support for llMessage:withVars:andCode and llProperty:withType for specifying low level code without having to stick C inside the compiler. Redo array built-in type to use this feature.
author | Mike Pavone <pavone@retrodev.com> |
---|---|
date | Sat, 21 Jul 2012 22:30:21 -0700 |
parents | 7f635666c73d |
children | 2a0463c46913 |
rev | line source |
---|---|
79
7f635666c73d
Add hash and int32 messages to string. Add hash message to int32. Update compile script
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
1 #{ |
7f635666c73d
Add hash and int32 messages to string. Add hash message to int32. Update compile script
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
2 main <- { |
7f635666c73d
Add hash and int32 messages to string. Add hash message to int32. Update compile script
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
3 print: "hash of 'foo' is " . ("foo" hash) . "\n" |
7f635666c73d
Add hash and int32 messages to string. Add hash message to int32. Update compile script
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
4 print: "hash of 'bar' is " . ("bar" hash) . "\n" |
7f635666c73d
Add hash and int32 messages to string. Add hash message to int32. Update compile script
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
5 print: "hash of 'foobar' is " . ("foobar" hash) . "\n" |
7f635666c73d
Add hash and int32 messages to string. Add hash message to int32. Update compile script
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
6 print: "hash of 1 is " . (1 hash) . "\n" |
7f635666c73d
Add hash and int32 messages to string. Add hash message to int32. Update compile script
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
7 print: "hash of 2 is " . (2 hash) . "\n" |
7f635666c73d
Add hash and int32 messages to string. Add hash message to int32. Update compile script
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
8 print: "hash of 3 is " . (3 hash) . "\n" |
7f635666c73d
Add hash and int32 messages to string. Add hash message to int32. Update compile script
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
9 } |
7f635666c73d
Add hash and int32 messages to string. Add hash message to int32. Update compile script
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
10 } |