1
0
Fork 0
mirror of https://github.com/Reuh/anselme.git synced 2025-10-27 16:49:31 +00:00

Third test batch

This commit is contained in:
Étienne Fildadut 2023-12-30 23:39:10 +01:00
parent 3edf65dc2a
commit 0eea4b80a6
7 changed files with 131 additions and 1 deletions

View file

@ -0,0 +1,13 @@
--# run #--
--- text ---
| {}"" {}"pierre" {}" is french" |
--- text ---
| {}"" {}"idk" {}" is esperanto" |
--- error ---
can't call overload overload<($(name::($(x) type(x) == t)) _), ($(name::($(x) type(x) == t)) _)>: no function match (type("nope", 5)), possible functions were:
• (name::($(x) type(x) == t)): type check failure for parameter name in function (name::($(x) type(x) == t))
• (name::($(x) type(x) == t)): type check failure for parameter name in function (name::($(x) type(x) == t))
↳ from test/tests/function custom type dispatch error.ans:14:2 in call: a(type(5, "nope"))
↳ from ? in block: :french name = "french name"…
--# saved #--
{}

View file

@ -0,0 +1,11 @@
--# run #--
--- text ---
| {}"" {}"bob" {}" is english or generic" |
--- text ---
| {}"" {}"pierre" {}" is french" |
--- text ---
| {}"" {}"idk" {}" is english or generic" |
--- return ---
()
--# saved #--
{}

View file

@ -0,0 +1,42 @@
--# run #--
--- text ---
| {}"numbers:" |
| {}"" {}"0" {}"" |
| {}"" {}"12" {}"" |
| {}"" {}"0.87" {}"" |
| {}"" {}"39.12" {}"" |
--- text ---
| {}"strings:" |
| {}"" {}"foo" {}"" |
--- text ---
| {}"tuple:" |
| {}"" {}"[4, 8, 9]" {}"" |
--- text ---
| {}"struct:" |
| {}"" {}"{1:9, 2:8, 7:4}" {}"" |
--- text ---
| {}"symbols:" |
| {}"" {}":ab" {}"" |
--- text ---
| {}"anchor:" |
| {}"" {}"#jdfe" {}"" |
| {}"" {}"#foo bar" {}"" |
--- text ---
| {}"boolean:" |
| {}"" {}"false" {}"" |
| {}"" {}"true" {}"" |
--- text ---
| {}"nil:" |
| {}"" {}"()" {}"" |
--- text ---
| {}"pair:" |
| {}"" {}"6:8" {}"" |
| {}"" {}"\"d\":[]" {}"" |
--- text ---
| {}"function:" |
| {}"" {}"($() 12)" {}"" |
| {}"" {}"($(x) x)" {}"" |
--- return ---
()
--# saved #--
{}