diff options
| author | Bruce Hill <bruce@bruce-hill.com> | 2025-04-04 17:06:09 -0400 |
|---|---|---|
| committer | Bruce Hill <bruce@bruce-hill.com> | 2025-04-04 17:06:09 -0400 |
| commit | 0b8074154e2671691050bdb3bcb33245625a056c (patch) | |
| tree | 1410e0c4e05c6372e876cd08f16d117e12868f41 /examples/shell | |
| parent | fadcb45baf1274e06cfe37b87655b9146aa52874 (diff) | |
First working compile of refactor to add explicit typing to declarations
and support untyped empty collections and `none`s
Diffstat (limited to 'examples/shell')
| -rw-r--r-- | examples/shell/shell.tm | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/shell/shell.tm b/examples/shell/shell.tm index 9ca9e059..dd26428f 100644 --- a/examples/shell/shell.tm +++ b/examples/shell/shell.tm @@ -24,7 +24,7 @@ lang Shell: func command(shell:Shell -> Command): return Command("sh", ["-c", shell.text]) - func result(shell:Shell, input="", input_bytes=[:Byte] -> ProgramResult): + func result(shell:Shell, input="", input_bytes:[Byte]=[] -> ProgramResult): return shell:command():result(input=input, input_bytes=input_bytes) func run(shell:Shell -> ExitType): @@ -33,7 +33,7 @@ lang Shell: func get_output(shell:Shell, input="", trim_newline=yes -> Text?): return shell:command():get_output(input=input, trim_newline=trim_newline) - func get_output_bytes(shell:Shell, input="", input_bytes=[:Byte] -> [Byte]?): + func get_output_bytes(shell:Shell, input="", input_bytes:[Byte]=[] -> [Byte]?): return shell:command():get_output_bytes(input=input, input_bytes=input_bytes) func by_line(shell:Shell -> func(->Text?)?): |
