mirror of
https://codeberg.org/ProgramSnail/lang_2023.git
synced 2025-12-05 22:48:42 +00:00
print & build visitor fixed and tested
This commit is contained in:
parent
c34523bd4f
commit
66a5dcfb4a
14 changed files with 91 additions and 62 deletions
|
|
@ -5,7 +5,7 @@ def fruit_cost : fruit = {
|
|||
}
|
||||
|
||||
def amount_to_string : x is_zero_separated = {
|
||||
const ans = match x with
|
||||
const ans = match x with
|
||||
| 0 ? is_zero_separated () -> "Zero"
|
||||
| 0 | 1 | 2 | 3 | 4 -> "Few"
|
||||
| x ? (5..9).contains x -> "Several"
|
||||
|
|
|
|||
|
|
@ -3,6 +3,6 @@ alias T1 = Int
|
|||
abstract (T2 : #A #B #C)
|
||||
|
||||
// Used to pre-compile module for some types
|
||||
// let T2 = Int
|
||||
// let T2 = Float
|
||||
// let T2 = Complex
|
||||
let T2 = Int
|
||||
let T2 = Float
|
||||
let T2 = Complex
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue