about summary refs log tree commit diff stats
path: root/090scenario_filesystem_test.mu
Commit message (Expand)AuthorAgeFilesLines
* 3389Kartik K. Agaram2016-09-171-7/+7
* 3388Kartik K. Agaram2016-09-171-6/+6
* 3385Kartik K. Agaram2016-09-171-3/+3
* 3379Kartik K. Agaram2016-09-171-10/+10
* 3341Kartik K. Agaram2016-09-121-1/+1
* 3337 - first use of type abbreviations: textKartik K. Agaram2016-09-121-4/+4
* 3256Kartik K. Agaram2016-08-261-0/+24
* 3254Kartik K. Agaram2016-08-261-1/+17
* 3253 - writing to fake files in scenariosKartik K. Agaram2016-08-251-0/+31
* 3231 - reading from fake files in scenariosKartik K. Agaram2016-08-201-0/+23
title='Blame the previous revision' href='/akkartik/mu/blame/global.mu?h=main&id=dfc6e268c7685e7ea5f5cdb434e62e63d2d7c915'>^
192d59d3 ^
fc2046a1 ^
1
2
3
4
5
6
7
8
9
10
11
12
13
14

                                                      
          
                                    
                                            
                                          
                              


     
         
                                
                                       
 
# example program: creating and using global variables

def main [
  # allocate 5 locations for globals
  global-space:space <- new location:type, 5
  # read to globals by using /space:global
  1:num/space:global <- copy 3
  foo
]

def foo [
  # ditto for writing to globals
  $print 1:num/space:global, 10/newline
]