diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2015-03-20 21:12:51 -0700 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2015-03-20 21:16:12 -0700 |
commit | a3d9828c190c86d9984a8e788f16dc10dfb95afa (patch) | |
tree | 3632b7319a88da648a99d595b38078ffd8d529b4 /cpp/.traces | |
parent | ad68bbce689969c4b0483a148c2a5260e9256fa7 (diff) | |
download | mu-a3d9828c190c86d9984a8e788f16dc10dfb95afa.tar.gz |
961 - done converting names?
I'm making two changes to how I compute field offsets: a) I just replace offset names up front, before I even manage field names. I don't bother disallowing x:integer and x:offset in the same function. Let's see if that leads us astray. Certainly saves code. b) I don't bother canonizing the first arg of a get since we know it has to have a type that is some number of 'address' followed by a record. Just assume that we have the right number of 'deref's.
Diffstat (limited to 'cpp/.traces')
-rw-r--r-- | cpp/.traces/convert_names_transforms_record_elements | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/cpp/.traces/convert_names_transforms_record_elements b/cpp/.traces/convert_names_transforms_record_elements new file mode 100644 index 00000000..99c78e6a --- /dev/null +++ b/cpp/.traces/convert_names_transforms_record_elements @@ -0,0 +1,31 @@ +parse/0: instruction: 18 +parse/0: ingredient: {name: "0", value: 0, type: 4, properties: [0: point]} +parse/0: ingredient: {name: "y", value: 0, type: 0, properties: [y: offset]} +parse/0: product: {name: "a", value: 0, type: 1, properties: [a: integer]} +parse/0: instruction: 18 +parse/0: ingredient: {name: "0", value: 0, type: 4, properties: [0: point]} +parse/0: ingredient: {name: "x", value: 0, type: 0, properties: [x: offset]} +parse/0: product: {name: "b", value: 0, type: 1, properties: [b: integer]} +name/0: field y of type point is at offset 1 +name/0: assign a 1 +name/0: field x of type point is at offset 0 +name/0: assign b 2 +after-brace/0: recipe main +after-brace/0: get ... +after-brace/0: get ... +run/0: instruction main/0 +run/0: ingredient 0 is 0 +run/0: ingredient 1 is y +run/0: address to copy is 1 +run/0: its type is 1 +mem/0: location 1 is 0 +run/0: product 0 is 0 +mem/0: storing in location 1 +run/0: instruction main/1 +run/0: ingredient 0 is 0 +run/0: ingredient 1 is x +run/0: address to copy is 0 +run/0: its type is 1 +mem/0: location 0 is 0 +run/0: product 0 is 0 +mem/0: storing in location 2 |