upload code

This commit is contained in:
Dominic 2022-10-16 20:14:55 +02:00
commit 3f507064ce
Signed by: msrd0
GPG key ID: DCC8C247452E98F9
111 changed files with 9258 additions and 0 deletions

View file

@ -0,0 +1,10 @@
Error: Type Mismatch
╭─[assignment-bool-int.txt:2:7]
1 │ let foo: bool = true;
· ──┬─
· ╰─── Expected type `bool`,
2 │ foo = 0;
· ┬
· ╰── but expression is of type `int`
───╯

View file

@ -0,0 +1,2 @@
let foo: bool = true;
foo = 0;

View file

@ -0,0 +1,10 @@
Error: Type Mismatch
╭─[assignment-rc-tuple-bool-int.txt:2:9]
1 │ let foo: Rc<(bool,)> = Rc((true,));
· ──┬─
· ╰─── Expected type `bool`,
2 │ foo.0 = 0;
· ┬
· ╰── but expression is of type `int`
───╯

View file

@ -0,0 +1,2 @@
let foo: Rc<(bool,)> = Rc((true,));
foo.0 = 0;

View file

@ -0,0 +1,10 @@
Error: Type Mismatch
╭─[assignment-rc-tuple-option-rc.txt:2:9]
1 │ let foo: Rc<(Option<bool>,)> = Rc((None,));
· ───┬──
· ╰──── Expected type `Option<bool>`,
2 │ foo.0 = Rc(true);
· ─┬
· ╰── but expression is of type `Rc<_>`
───╯

View file

@ -0,0 +1,2 @@
let foo: Rc<(Option<bool>,)> = Rc((None,));
foo.0 = Rc(true);

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[declaration-bool-int-arithmetic.txt:1:17]
1 │ let foo: bool = 1 + 2;
· ──┬─ ──┬──
· ╰─────────── Expected type `bool`,
· │
· ╰──── but expression is of type `int`
───╯

View file

@ -0,0 +1 @@
let foo: bool = 1 + 2;

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[declaration-bool-int-negation.txt:2:17]
2 │ let foo: bool = -one;
· ──┬─ ┬
· ╰─────── Expected type `bool`,
· │
· ╰── but expression is of type `int`
───╯

View file

@ -0,0 +1,2 @@
let one: int = 1;
let foo: bool = -one;

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[declaration-bool-int-tuple-bool-bool-tuple.txt:1:31]
1 │ let foo: (bool, int) = (true, true);
· ─┬─ ──┬─
· ╰────────────────── Expected type `int`,
· │
· ╰─── but expression is of type `bool`
───╯

View file

@ -0,0 +1 @@
let foo: (bool, int) = (true, true);

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[declaration-bool-int.txt:1:17]
1 │ let foo: bool = 0;
· ──┬─ ┬
· ╰─────── Expected type `bool`,
· │
· ╰── but expression is of type `int`
───╯

View file

@ -0,0 +1 @@
let foo: bool = 0;

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[declaration-int-bool-conjunction.txt:1:16]
1 │ let foo: int = true && true;
· ─┬─ ──────┬─────
· ╰────────────────── Expected type `int`,
· │
· ╰─────── but expression is of type `bool`
───╯

View file

@ -0,0 +1 @@
let foo: int = true && true;

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[declaration-int-bool-negation.txt:2:16]
2 │ let foo: int = !yes;
· ─┬─ ┬
· ╰─────── Expected type `int`,
· │
· ╰── but expression is of type `bool`
───╯

View file

@ -0,0 +1,2 @@
let yes: bool = true;
let foo: int = !yes;

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[declaration-int-bool.txt:1:16]
1 │ let foo: int = true;
· ─┬─ ──┬─
· ╰────────── Expected type `int`,
· │
· ╰─── but expression is of type `bool`
───╯

View file

@ -0,0 +1 @@
let foo: int = true;

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[declaration-int-int-comparison.txt:1:16]
1 │ let foo: int = 1 == 2;
· ─┬─ ───┬──
· ╰──────────── Expected type `int`,
· │
· ╰──── but expression is of type `bool`
───╯

View file

@ -0,0 +1 @@
let foo: int = 1 == 2;

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[declaration-int-tuple-bool-tuple.txt:1:20]
1 │ let foo: (int,) = (true,);
· ─┬─ ──┬─
· ╰───────────── Expected type `int`,
· │
· ╰─── but expression is of type `bool`
───╯

View file

@ -0,0 +1 @@
let foo: (int,) = (true,);

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[declaration-unit-one-tuple.txt:1:15]
1 │ let foo: () = (1,);
· ─┬ ──┬─
· ╰───────── Expected tuple with 0 elements,
· │
· ╰─── but expression has 1 elements
───╯

View file

@ -0,0 +1 @@
let foo: () = (1,);

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[expression-arithmetic-int-bool.txt:1:20]
1 │ let foo: int = 1 + true;
· ┬ ──┬─
· ╰─────── Expected type `int`,
· │
· ╰─── but expression is of type `bool`
───╯

View file

@ -0,0 +1 @@
let foo: int = 1 + true;

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[expression-comparison-int-bool.txt:1:22]
1 │ let foo: bool = 1 == true;
· ─┬ ──┬─
· ╰─────── Expected type `int`,
· │
· ╰─── but expression is of type `bool`
───╯

View file

@ -0,0 +1 @@
let foo: bool = 1 == true;

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[expression-conjunction-bool-int.txt:1:25]
1 │ let foo: bool = true || 1;
· ─┬ ┬
· ╰──── Expected type `bool`,
· │
· ╰── but expression is of type `int`
───╯

View file

@ -0,0 +1 @@
let foo: bool = true || 1;

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[expression-int-0.txt:2:16]
2 │ let bar: int = foo.0;
· ──┬─┬
· ╰──── Expression is of type `int`,
· │
· ╰── but expected type `(_, ..)`
───╯

View file

@ -0,0 +1,2 @@
let foo: int = 1;
let bar: int = foo.0;

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[expression-minus-bool.txt:1:17]
1 │ let foo: int = -true;
· ┬──┬─
· ╰────── Expected type `int`,
· │
· ╰─── but expression is of type `bool`
───╯

View file

@ -0,0 +1 @@
let foo: int = -true;

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[expression-not-int.txt:1:18]
1 │ let foo: bool = !0;
· ┬┬
· ╰─── Expected type `bool`,
· │
· ╰── but expression is of type `int`
───╯

View file

@ -0,0 +1 @@
let foo: bool = !0;

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[expression-unit-0.txt:1:16]
1 │ let foo: int = ().0;
· ─┬┬─
· ╰──── Found tuple with 0 elements,
· │
· ╰─── but expression requires at least 1 elements
───╯

View file

@ -0,0 +1 @@
let foo: int = ().0;

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[if-condition-int.txt:1:4]
1 │ if 0 {}
· ─┬ ┬
· ╰──── Expected type `bool`,
· │
· ╰── but expression is of type `int`
───╯

View file

@ -0,0 +1 @@
if 0 {}

View file

@ -0,0 +1,9 @@
Error: Type Mismatch
╭─[while-condition-int.txt:1:7]
1 │ while 0 {}
· ──┬── ┬
· ╰────── Expected type `bool`,
· │
· ╰── but expression is of type `int`
───╯

View file

@ -0,0 +1 @@
while 0 {}