Mercurial > repos > rhope
annotate testdictsetget.rhope @ 135:18a4403fe576
Javascript backend can now produce broken output. Needs fixes plus port of standard lib
author | Mike Pavone <pavone@retrodev.com> |
---|---|
date | Sun, 14 Nov 2010 03:09:49 -0500 |
parents | e09c2d1d6d5b |
children |
rev | line source |
---|---|
83
27bb051d631c
Initial implementation of Dictionary
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
1 |
27bb051d631c
Initial implementation of Dictionary
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
2 |
27bb051d631c
Initial implementation of Dictionary
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
3 Main[] |
27bb051d631c
Initial implementation of Dictionary
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
4 { |
27bb051d631c
Initial implementation of Dictionary
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
5 dict <- [[[[Dictionary[] |
27bb051d631c
Initial implementation of Dictionary
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
6 ]Set["foo", "bar"] |
27bb051d631c
Initial implementation of Dictionary
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
7 ]Set["bovine","moo"] |
27bb051d631c
Initial implementation of Dictionary
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
8 ]Set["food", "fight"] |
27bb051d631c
Initial implementation of Dictionary
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
9 ]Set["fool", "wise"] |
27bb051d631c
Initial implementation of Dictionary
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
10 |
27bb051d631c
Initial implementation of Dictionary
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
11 Print[[dict]Index["food"]] |
27bb051d631c
Initial implementation of Dictionary
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
12 { Print[[dict]Index["bovine"]] |
27bb051d631c
Initial implementation of Dictionary
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
13 { Print[[dict]Index["foo"]] |
99
e09c2d1d6d5b
Got dataflow graph code working in compiler (nworker_c.rhope)
Mike Pavone <pavone@retrodev.com>
parents:
83
diff
changeset
|
14 { Print[[dict]Index["fool"]] |
e09c2d1d6d5b
Got dataflow graph code working in compiler (nworker_c.rhope)
Mike Pavone <pavone@retrodev.com>
parents:
83
diff
changeset
|
15 { |
e09c2d1d6d5b
Got dataflow graph code working in compiler (nworker_c.rhope)
Mike Pavone <pavone@retrodev.com>
parents:
83
diff
changeset
|
16 Print[[[[Dictionary[] |
e09c2d1d6d5b
Got dataflow graph code working in compiler (nworker_c.rhope)
Mike Pavone <pavone@retrodev.com>
parents:
83
diff
changeset
|
17 ]Set["+@Foo", "bar"] |
e09c2d1d6d5b
Got dataflow graph code working in compiler (nworker_c.rhope)
Mike Pavone <pavone@retrodev.com>
parents:
83
diff
changeset
|
18 ]Set["+", "add"] |
e09c2d1d6d5b
Got dataflow graph code working in compiler (nworker_c.rhope)
Mike Pavone <pavone@retrodev.com>
parents:
83
diff
changeset
|
19 ]Index["+"]] |
e09c2d1d6d5b
Got dataflow graph code working in compiler (nworker_c.rhope)
Mike Pavone <pavone@retrodev.com>
parents:
83
diff
changeset
|
20 }}}} |
83
27bb051d631c
Initial implementation of Dictionary
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
21 } |
27bb051d631c
Initial implementation of Dictionary
Mike Pavone <pavone@retrodev.com>
parents:
diff
changeset
|
22 |