about summary refs log tree commit diff stats
path: root/055shape_shifting_container.cc
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2016-09-17 00:06:04 -0700
committerKartik K. Agaram <vc@akkartik.com>2016-09-17 00:06:04 -0700
commit7c9def3c5a35c07afdc95b383d6ff85a7c16ef0b (patch)
treec69ae0c6ec4fca45e23eed42ffbcce5fdbc71eae /055shape_shifting_container.cc
parent14b0932a54916349b531e804acc34a1c3caf70cf (diff)
downloadmu-7c9def3c5a35c07afdc95b383d6ff85a7c16ef0b.tar.gz
3376 - start maximally using all type abbreviations
It might be too much, particularly if students start peeking inside .mu
files early. But worth a shot for not just to iron out the kinks in the
abbreviation system.
Diffstat (limited to '055shape_shifting_container.cc')
-rw-r--r--055shape_shifting_container.cc16
1 files changed, 8 insertions, 8 deletions
diff --git a/055shape_shifting_container.cc b/055shape_shifting_container.cc
index ef165c91..26bb7467 100644
--- a/055shape_shifting_container.cc
+++ b/055shape_shifting_container.cc
@@ -52,9 +52,9 @@ container foo:_a:_b [
   y:_b
 ]
 def main [
-  1:address:array:character <- new [abc]
+  1:text <- new [abc]
   # compound types for type ingredients
-  {2: (foo number (address array character))} <- merge 34/x, 1:address:array:character/y
+  {2: (foo number (address array character))} <- merge 34/x, 1:text/y
 ]
 $error: 0
 
@@ -68,8 +68,8 @@ container bar:_a:_b [
   {data: (foo _a (address _b))}
 ]
 def main [
-  1:address:array:character <- new [abc]
-  2:bar:number:array:character <- merge 34/x, 1:address:array:character/y
+  1:text <- new [abc]
+  2:bar:number:array:character <- merge 34/x, 1:text/y
 ]
 $error: 0
 
@@ -278,10 +278,10 @@ container foo:_a:_b [
   y:_b
 ]
 def main [
-  1:address:array:character <- new [abc]
-  {2: (foo number (address array character))} <- merge 34/x, 1:address:array:character/y
-  3:address:array:character <- get {2: (foo number (address array character))}, y:offset
-  4:boolean <- equal 1:address:array:character, 3:address:array:character
+  1:text <- new [abc]
+  {2: (foo number (address array character))} <- merge 34/x, 1:text/y
+  3:text <- get {2: (foo number (address array character))}, y:offset
+  4:boolean <- equal 1:text, 3:text
 ]
 +mem: storing 1 in location 4