diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2015-04-19 00:21:24 -0700 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2015-04-19 00:21:24 -0700 |
commit | 69d95127b03ba92be03ed42beeab099dbcc808b9 (patch) | |
tree | 9b6ea207b77d2bc81d28adc37015b08edc570a8e /cpp/043space | |
parent | ecc40a1e1b837f5a22a0b83c4b694c9e3a65e446 (diff) | |
download | mu-69d95127b03ba92be03ed42beeab099dbcc808b9.tar.gz |
1101
Diffstat (limited to 'cpp/043space')
-rw-r--r-- | cpp/043space | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/cpp/043space b/cpp/043space index c285f65f..cc9c161e 100644 --- a/cpp/043space +++ b/cpp/043space @@ -8,7 +8,7 @@ # then location 0 is really location 11, location 1 is really location 12, and so on. recipe main [ 10:integer <- copy 5:literal # pretend array; in practice we'll use new - default-space:address:space <- copy 10:literal + default-space:address:array:location <- copy 10:literal 1:integer <- copy 23:literal ] +mem: storing 23 in location 12 @@ -20,7 +20,7 @@ recipe main [ # pretend array 1000:integer <- copy 5:literal # actual start of this function - default-space:address:space <- copy 1000:literal + default-space:address:array:location <- copy 1000:literal 1:address:integer <- copy 3:literal 8:integer/raw <- copy 1:address:integer/deref ] @@ -62,7 +62,7 @@ recipe main [ # pretend array 1000:integer <- copy 5:literal # actual start of this function - default-space:address:space <- copy 1000:literal + default-space:address:array:location <- copy 1000:literal 1:address:point <- copy 12:literal 9:integer/raw <- get 1:address:point/deref, 1:offset ] @@ -82,7 +82,7 @@ recipe main [ # pretend array 1000:integer <- copy 5:literal # actual start of this function - default-space:address:space <- copy 1000:literal + default-space:address:array:location <- copy 1000:literal 1:address:array:integer <- copy 12:literal 9:integer/raw <- index 1:address:array:integer/deref, 1:literal ] @@ -118,8 +118,8 @@ int address(int offset, int base) { :(scenario "get_default_space") recipe main [ - default-space:address:space <- copy 10:literal - 1:integer/raw <- copy default-space:address:space + default-space:address:array:location <- copy 10:literal + 1:integer/raw <- copy default-space:address:array:location ] +mem: storing 10 in location 1 |