mirror of
https://github.com/ProvableHQ/leo.git
synced 2024-09-11 13:56:58 +03:00
Error cleanup; regen test expectations
This commit is contained in:
parent
75e3e916e5
commit
3e867010b4
@ -82,7 +82,7 @@ pub struct UnaryExpression {
|
||||
|
||||
impl fmt::Display for UnaryExpression {
|
||||
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
|
||||
write!(f, "{}{}", self.op.as_str(), self.receiver)
|
||||
write!(f, "({} {})", self.op.as_str(), self.receiver)
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -37,7 +37,7 @@ impl<'a> StatementReconstructor for ConstantFolder<'a> {
|
||||
|
||||
fn reconstruct_definition(&mut self, input: DefinitionStatement) -> Statement {
|
||||
// We grab the place and its possible const value.
|
||||
let (value, const_val) = self.reconstruct_expression(input.value);
|
||||
let (value, const_val) = self.reconstruct_expression(input.value.clone());
|
||||
let mut st = self.symbol_table.borrow_mut();
|
||||
|
||||
if const_val.is_none() {
|
||||
@ -46,6 +46,7 @@ impl<'a> StatementReconstructor for ConstantFolder<'a> {
|
||||
DeclarationType::Let => {}
|
||||
DeclarationType::Const => {
|
||||
self.handler.emit_err(TypeCheckerError::cannot_assign_to_const_var(
|
||||
input.value,
|
||||
input.variable_name,
|
||||
input.span,
|
||||
));
|
||||
|
@ -70,7 +70,11 @@ impl<'a> StatementVisitor<'a> for TypeChecker<'a> {
|
||||
|
||||
let var_type = if let Some(var) = self.symbol_table.borrow_mut().lookup_variable(var_name.name) {
|
||||
match &var.variable_type {
|
||||
VariableType::Const => self.emit_err(TypeCheckerError::cannot_assign_to_const_var(var_name, var.span)),
|
||||
VariableType::Const => self.emit_err(TypeCheckerError::cannot_assign_to_const_var(
|
||||
&input.place,
|
||||
var_name,
|
||||
input.span,
|
||||
)),
|
||||
VariableType::Input(ParamMode::Const) => {
|
||||
self.emit_err(TypeCheckerError::cannot_assign_to_const_input(var_name, var.span))
|
||||
}
|
||||
|
@ -40,7 +40,7 @@ create_messages!(
|
||||
@formatted
|
||||
unary_overflow {
|
||||
args: (left: impl Display, op: impl Display),
|
||||
msg: format!("The const operation `{left}{} {op}` causes an overflow.", type_name(&left)),
|
||||
msg: format!("The const operation `({op} {left}{}` causes an overflow.", type_name(&left)),
|
||||
help: None,
|
||||
}
|
||||
|
||||
|
@ -44,9 +44,9 @@ create_messages!(
|
||||
/// For when the user tries to assign to a const input.
|
||||
@formatted
|
||||
cannot_assign_to_const_var {
|
||||
args: (var: impl Display),
|
||||
args: (expr: impl Display, var: impl Display),
|
||||
msg: format!(
|
||||
"Cannot assign to const variable `{var}`",
|
||||
"Cannot assign a non-const or invalid expression `{expr}` to const variable `{var}`",
|
||||
),
|
||||
help: None,
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
/*
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
expectation: Pass
|
||||
input_file: inputs/int.in
|
||||
*/
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
/*
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
expectation: Pass
|
||||
input_file: inputs/dummy.in
|
||||
*/
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
/*
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
expectation: Skip
|
||||
*/
|
||||
|
||||
record Token {
|
||||
|
32
tests/compiler/records/init_expression_direct.leo
Normal file
32
tests/compiler/records/init_expression_direct.leo
Normal file
@ -0,0 +1,32 @@
|
||||
/*
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
*/
|
||||
|
||||
record Token {
|
||||
// The token owner.
|
||||
owner: address,
|
||||
// The Aleo balance (in gates).
|
||||
gates: u64,
|
||||
// The token amount.
|
||||
amount: u64,
|
||||
}
|
||||
|
||||
function mint(owner: address, amount: u64) -> Token {
|
||||
return Token {
|
||||
owner,
|
||||
gates: 0u64,
|
||||
amount,
|
||||
};
|
||||
}
|
||||
|
||||
function main(x: address) -> u64 {
|
||||
const c: u64 = 1u64;
|
||||
let t: Token = Token {
|
||||
owner: x,
|
||||
gates: 0u64,
|
||||
amount: c,
|
||||
};
|
||||
|
||||
return t.gates;
|
||||
}
|
@ -1,6 +1,6 @@
|
||||
/*
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
expectation: Skip
|
||||
*/
|
||||
|
||||
record Token {
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: fe880c907d0257c9fc8314b8b98cabd8a8282b587d2d618408cc3cd8e528fda5
|
||||
initial_ast: 3c29b1703692d5095c7d346a8597e7bc96ab6b272d344d4873359aec19a90238
|
||||
unrolled_ast: 3c29b1703692d5095c7d346a8597e7bc96ab6b272d344d4873359aec19a90238
|
||||
constant_folded_ast: 70b951d032a54c8744365a519d4f0cb7c07a2e8407e1c210105f2a1ac82be9ca
|
||||
unrolled_ast: 70b951d032a54c8744365a519d4f0cb7c07a2e8407e1c210105f2a1ac82be9ca
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: 00f5aba05e4efae5a125eb52f02f16400132085b8a34919d910aa40c6c405a22
|
||||
initial_ast: 90154a6a01ee247ee0336cb3abcced38a628a9918e0554127dfe5ca7caa34dc7
|
||||
constant_folded_ast: 90154a6a01ee247ee0336cb3abcced38a628a9918e0554127dfe5ca7caa34dc7
|
||||
unrolled_ast: 90154a6a01ee247ee0336cb3abcced38a628a9918e0554127dfe5ca7caa34dc7
|
||||
|
@ -4,5 +4,7 @@ expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 03e9df3bd1409f4af9e2a7f55130bc52f27d41f32a624ffa27f0ab114bf6fbf4
|
||||
- initial_input_ast: 9a0d83e67799f28ec6613d9aac9d921aea81eebb68c9682de33c69036c4a924f
|
||||
initial_ast: e0fde99efa3e6ec987044326b17bc96d16379992b2a30585ed85878285fb761c
|
||||
unrolled_ast: e0fde99efa3e6ec987044326b17bc96d16379992b2a30585ed85878285fb761c
|
||||
constant_folded_ast: 35db6895f176b36f760fcea336764e8bb7db772c00cd49c3f2dc614a54f33fa0
|
||||
unrolled_ast: 35db6895f176b36f760fcea336764e8bb7db772c00cd49c3f2dc614a54f33fa0
|
||||
|
@ -6,4 +6,5 @@ outputs:
|
||||
- initial_input_ast: ec3cfeb93ea66a530150a5c5e2bd396688b3ef9b9fb0bcb961c62dac4daa064e
|
||||
- initial_input_ast: cb1d48114c10b2b732ad47a46fc8d05bf7a3e783da89e7f00065244bfc8d15c8
|
||||
initial_ast: d36a542762bed92ce775751e99f5e47dbbc9014a0d4d00deb0fa8abb7af7f2e7
|
||||
unrolled_ast: d36a542762bed92ce775751e99f5e47dbbc9014a0d4d00deb0fa8abb7af7f2e7
|
||||
constant_folded_ast: 56aa2abaee69988e3c9c3c18a64249c0c72566222278a5b9389c0b9a4fc65b9e
|
||||
unrolled_ast: 56aa2abaee69988e3c9c3c18a64249c0c72566222278a5b9389c0b9a4fc65b9e
|
||||
|
@ -8,4 +8,5 @@ outputs:
|
||||
- initial_input_ast: 4c5eeffd0306b20c8deece509782b81ea8583245f650e40a4a300d517f6ed5f4
|
||||
- initial_input_ast: a56b3f9908dec2acaed302691d4fe0c2cf046f0deb8f188f617e042e75502f71
|
||||
initial_ast: 86e914325e67e129cc7e6738b7924fb1b9d72e49b008c8dd0c4da86d57d2132d
|
||||
constant_folded_ast: 86e914325e67e129cc7e6738b7924fb1b9d72e49b008c8dd0c4da86d57d2132d
|
||||
unrolled_ast: 86e914325e67e129cc7e6738b7924fb1b9d72e49b008c8dd0c4da86d57d2132d
|
||||
|
@ -8,4 +8,5 @@ outputs:
|
||||
- initial_input_ast: 7a1c39dec2388ab801496ceb17ca85665d2f515269929925b7cc9018e14297ea
|
||||
- initial_input_ast: 650984ca5077d11a815889421656b7735b4c6bd320bdf68b4deb87dfc0f49388
|
||||
initial_ast: fe582e7789f2199f81249864983873612bc4f24ae7086fac13f88515c2f89d81
|
||||
constant_folded_ast: fe582e7789f2199f81249864983873612bc4f24ae7086fac13f88515c2f89d81
|
||||
unrolled_ast: fe582e7789f2199f81249864983873612bc4f24ae7086fac13f88515c2f89d81
|
||||
|
@ -8,4 +8,5 @@ outputs:
|
||||
- initial_input_ast: 4c5eeffd0306b20c8deece509782b81ea8583245f650e40a4a300d517f6ed5f4
|
||||
- initial_input_ast: a56b3f9908dec2acaed302691d4fe0c2cf046f0deb8f188f617e042e75502f71
|
||||
initial_ast: e4dded56ee2ee6cbd2bbf301a3c87c09d35aafad9b66b8a7a8592f9d16aad47f
|
||||
constant_folded_ast: e4dded56ee2ee6cbd2bbf301a3c87c09d35aafad9b66b8a7a8592f9d16aad47f
|
||||
unrolled_ast: e4dded56ee2ee6cbd2bbf301a3c87c09d35aafad9b66b8a7a8592f9d16aad47f
|
||||
|
@ -8,4 +8,5 @@ outputs:
|
||||
- initial_input_ast: 4c5eeffd0306b20c8deece509782b81ea8583245f650e40a4a300d517f6ed5f4
|
||||
- initial_input_ast: a56b3f9908dec2acaed302691d4fe0c2cf046f0deb8f188f617e042e75502f71
|
||||
initial_ast: 90bb6f3c3453976ec13875f39ad9ae5c852f3d24bd76e6c170e526f11f91b626
|
||||
constant_folded_ast: 90bb6f3c3453976ec13875f39ad9ae5c852f3d24bd76e6c170e526f11f91b626
|
||||
unrolled_ast: 90bb6f3c3453976ec13875f39ad9ae5c852f3d24bd76e6c170e526f11f91b626
|
||||
|
@ -8,4 +8,5 @@ outputs:
|
||||
- initial_input_ast: 19f1be52a19445695f23724e1979b362dd3fcf31aace997c829e2206dc1cccbe
|
||||
- initial_input_ast: d2fc1992beaf062678bbf6c3e862820dbbea39926589afcdc46c19c8669f0e37
|
||||
initial_ast: be62eafa579fa7e239f5c9cd91bfea1e072b3db6192ff9a1c29be78dd9faf680
|
||||
constant_folded_ast: be62eafa579fa7e239f5c9cd91bfea1e072b3db6192ff9a1c29be78dd9faf680
|
||||
unrolled_ast: be62eafa579fa7e239f5c9cd91bfea1e072b3db6192ff9a1c29be78dd9faf680
|
||||
|
@ -8,4 +8,5 @@ outputs:
|
||||
- initial_input_ast: 4c5eeffd0306b20c8deece509782b81ea8583245f650e40a4a300d517f6ed5f4
|
||||
- initial_input_ast: a56b3f9908dec2acaed302691d4fe0c2cf046f0deb8f188f617e042e75502f71
|
||||
initial_ast: 907f4bebafce2bdcd67c2f8f00282e71b50b1fddc7144f5266e6012ef9f48bf5
|
||||
constant_folded_ast: 907f4bebafce2bdcd67c2f8f00282e71b50b1fddc7144f5266e6012ef9f48bf5
|
||||
unrolled_ast: 907f4bebafce2bdcd67c2f8f00282e71b50b1fddc7144f5266e6012ef9f48bf5
|
||||
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
outputs:
|
||||
- "Error [EPAR0370017]: Could not lex the following content: `''`.\n"
|
5
tests/expectations/compiler/compiler/char/neq_fail.out
Normal file
5
tests/expectations/compiler/compiler/char/neq_fail.out
Normal file
@ -0,0 +1,5 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
outputs:
|
||||
- "Error [EPAR0370017]: Could not lex the following content: `'a'`.\n"
|
5
tests/expectations/compiler/compiler/char/out_fail.out
Normal file
5
tests/expectations/compiler/compiler/char/out_fail.out
Normal file
@ -0,0 +1,5 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
outputs:
|
||||
- "Error [EPAR0370017]: Could not lex the following content: `'z'`.\n"
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: f1af7e79dff9ede0d2a1c88d5d22801cb3dfe3a9fb34e93bca646e29a61e9f65
|
||||
initial_ast: 7d8c6817927782cd181a5a3429f72139b452ec511ec5352dfe27b98a3b7b5955
|
||||
unrolled_ast: 7d8c6817927782cd181a5a3429f72139b452ec511ec5352dfe27b98a3b7b5955
|
||||
constant_folded_ast: cf9eabd393ba20c8d4855c04cc63589cd5f268c80a951235637ae4304726b406
|
||||
unrolled_ast: cf9eabd393ba20c8d4855c04cc63589cd5f268c80a951235637ae4304726b406
|
||||
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
outputs:
|
||||
- "Error [ETYC0372002]: Cannot assign a non-const or invalid expression `{x, y: 0u8}` to const variable `a`\n --> compiler-test:9:5\n |\n 9 | const a: Foo = Foo { x, y: 0u8 };\n | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n"
|
@ -3,6 +3,7 @@ namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: no input
|
||||
initial_ast: d1b4db4f3be418df4f8b42d12e90491aa6fa4f68f07a3b0ac3b4ef6eb8091b17
|
||||
unrolled_ast: d1b4db4f3be418df4f8b42d12e90491aa6fa4f68f07a3b0ac3b4ef6eb8091b17
|
||||
- initial_input_ast: a531846d2ddba4fb243566b53004d496aaefb05dfdb4b66a6cae4610d464a711
|
||||
initial_ast: 22d9e683ff7580285d14d96f8d76d6ff6517db55dee49f7bd7bf6f7fafab563d
|
||||
constant_folded_ast: 22d9e683ff7580285d14d96f8d76d6ff6517db55dee49f7bd7bf6f7fafab563d
|
||||
unrolled_ast: 22d9e683ff7580285d14d96f8d76d6ff6517db55dee49f7bd7bf6f7fafab563d
|
||||
|
@ -2,4 +2,4 @@
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
outputs:
|
||||
- "Error [EPAR0370005]: expected -> -- found '{'\n --> compiler-test:7:17\n |\n 7 | function main() {\n | ^"
|
||||
- "Error [ETYC0372013]: Circuit initialization expression for `Foo` is missing member `x`.\n --> compiler-test:9:20\n |\n 9 | const a: Foo = Foo { y: 0u32 };\n | ^^^^^^^^^^^^^^^\n"
|
||||
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 4bfe21d9055d813cf1a65ff07499e4a1085109b40b91556513610952e3042e98
|
||||
initial_ast: 74ce81f500de91fc19fd9ea1132b6ead2c53df7e23900897587e9b0f7b05fee2
|
||||
constant_folded_ast: 74ce81f500de91fc19fd9ea1132b6ead2c53df7e23900897587e9b0f7b05fee2
|
||||
unrolled_ast: 74ce81f500de91fc19fd9ea1132b6ead2c53df7e23900897587e9b0f7b05fee2
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
outputs:
|
||||
- "Error [ETYC0372012]: Circuit expected `1` members, but got `2`\n --> compiler-test:8:20\n |\n 8 | const a: Foo = Foo { x, x };\n | ^^^^^^^^^^^^\n"
|
@ -2,4 +2,4 @@
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
outputs:
|
||||
- "Error [EPAR0370005]: expected -> -- found '{'\n --> compiler-test:7:17\n |\n 7 | function main() {\n | ^"
|
||||
- "Error [EPAR0370018]: Could not parse the implicit value: 1.\n --> compiler-test:8:19\n |\n 8 | const y: u8 = 1;\n | ^"
|
||||
|
@ -2,4 +2,4 @@
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
outputs:
|
||||
- "Error [EPAR0370005]: expected -> -- found '{'\n --> compiler-test:3:17\n |\n 3 | function main() {\n | ^"
|
||||
- "Error [ETYC0372005]: Unknown circuit `Foo`\n --> compiler-test:4:20\n |\n 4 | const a: Foo = Foo { };\n | ^^^\n"
|
||||
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
outputs:
|
||||
- "Error [ETYC0372012]: Circuit expected `1` members, but got `2`\n --> compiler-test:8:20\n |\n 8 | const a: Foo = Foo { x: 0u8, x: 1u8 };\n | ^^^^^^^^^^^^^^^^^^^^^^\n"
|
@ -3,6 +3,7 @@ namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 29f6139d908d390f890f04d8ee620757d29b7f71cd48c46ff65bc1e70aae840c
|
||||
initial_ast: 930940759647baf7f6c4764b33bf6653fb3971ccdd5362466babf392788062bf
|
||||
unrolled_ast: 930940759647baf7f6c4764b33bf6653fb3971ccdd5362466babf392788062bf
|
||||
- initial_input_ast: 0f6e6634d7fbd2d3726902cdd699ded4914f9f112d19a3c4779e672e9b727107
|
||||
initial_ast: 2890951527970b4a7ac427db5c6eb68b184037e38528c1a03ab18b51ea03fba9
|
||||
constant_folded_ast: 2890951527970b4a7ac427db5c6eb68b184037e38528c1a03ab18b51ea03fba9
|
||||
unrolled_ast: 2890951527970b4a7ac427db5c6eb68b184037e38528c1a03ab18b51ea03fba9
|
||||
|
@ -2,4 +2,4 @@
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
outputs:
|
||||
- "Error [EPAR0370005]: expected -> -- found '{'\n --> compiler-test:7:17\n |\n 7 | function main() {\n | ^"
|
||||
- "Error [EPAR0370005]: expected : -- found '='\n --> compiler-test:9:15\n |\n 9 | const err = a.y;\n | ^"
|
||||
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
outputs:
|
||||
- "Error [ETYC0372012]: Circuit expected `2` members, but got `1`\n --> compiler-test:9:20\n |\n 9 | const a: Foo = Foo { y: 0u32 };\n | ^^^^^^^^^^^^^^^\nError [ETYC0372013]: Circuit initialization expression for `Foo` is missing member `x`.\n --> compiler-test:9:20\n |\n 9 | const a: Foo = Foo { y: 0u32 };\n | ^^^^^^^^^^^^^^^\n"
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
outputs:
|
||||
- "Error [EAST0372009]: circuit `Bar` shadowed by\n --> compiler-test:8:5\n |\n 8 | const Bar: u32 = 66u32;\n | ^^^^^^^^^^^^^^^^^^^^^^\n"
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: 15a1f00a6c0ca8141202e45e534b7afd196e9391c184a4efd94f0d0ccf04a59d
|
||||
initial_ast: f8f5c01bf6a9bcaa57c44e48e4b1d873a526b7f24efce54928b5bd7d17568f54
|
||||
constant_folded_ast: f8f5c01bf6a9bcaa57c44e48e4b1d873a526b7f24efce54928b5bd7d17568f54
|
||||
unrolled_ast: f8f5c01bf6a9bcaa57c44e48e4b1d873a526b7f24efce54928b5bd7d17568f54
|
||||
|
@ -6,4 +6,5 @@ outputs:
|
||||
- initial_input_ast: 8b94c0dbc84f44bd29c614b87947e625ad136549ea29ff18233ba5b01ce63c9b
|
||||
- initial_input_ast: a62874e75304ab81d487909be1c6b1efa2e5756a2980b46e3bb1368586c3ee83
|
||||
initial_ast: 4adda6e6c732a161071c21da51ba8902e7f351722971fd1834a560e5f672d2e8
|
||||
constant_folded_ast: 4adda6e6c732a161071c21da51ba8902e7f351722971fd1834a560e5f672d2e8
|
||||
unrolled_ast: 4adda6e6c732a161071c21da51ba8902e7f351722971fd1834a560e5f672d2e8
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: 14cd2c781b154a9037de84e945cfb348e9c587cef94d3e1f3be83e4306f92a0e
|
||||
initial_ast: d8ad2aeb376197baa9983ae969d6e5d2a190675c8001a66a6062b7c3c9fda6b8
|
||||
constant_folded_ast: d8ad2aeb376197baa9983ae969d6e5d2a190675c8001a66a6062b7c3c9fda6b8
|
||||
unrolled_ast: d8ad2aeb376197baa9983ae969d6e5d2a190675c8001a66a6062b7c3c9fda6b8
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: fd19d82c3aba921f01b37174e3eb7fb603438506fe511657e21235b9fb3647d2
|
||||
initial_ast: 003f8bcd2065401f1ed21d8ca268a02a7da3c0f7dcbbfd1b145ba76b9cf9885d
|
||||
constant_folded_ast: 003f8bcd2065401f1ed21d8ca268a02a7da3c0f7dcbbfd1b145ba76b9cf9885d
|
||||
unrolled_ast: 003f8bcd2065401f1ed21d8ca268a02a7da3c0f7dcbbfd1b145ba76b9cf9885d
|
||||
|
@ -6,4 +6,5 @@ outputs:
|
||||
- initial_input_ast: 12a0efa27e9b65c045088e471e6c254bb71c60cca4eb369f41e83a29301130cf
|
||||
- initial_input_ast: 5622eb396c2aea656e3bfa6b1ad0d39fce6bc221978a13c9be4d750da46cfc48
|
||||
initial_ast: 6c7e6756250ed03109d11b90db2cd72e3db761c0ef2d1f8467d8a069df29cfb2
|
||||
constant_folded_ast: 6c7e6756250ed03109d11b90db2cd72e3db761c0ef2d1f8467d8a069df29cfb2
|
||||
unrolled_ast: 6c7e6756250ed03109d11b90db2cd72e3db761c0ef2d1f8467d8a069df29cfb2
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: 0961f603812e241567b6e3ef5adb458309f1829eb2c08a216efccb17bea89faf
|
||||
initial_ast: 2b70c901581ffad2061e1a3ad8cef937b7fc3d251a7967704c28ce0613aa0217
|
||||
constant_folded_ast: 2b70c901581ffad2061e1a3ad8cef937b7fc3d251a7967704c28ce0613aa0217
|
||||
unrolled_ast: 2b70c901581ffad2061e1a3ad8cef937b7fc3d251a7967704c28ce0613aa0217
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: f18a0e019ca4719c4c4ef5b7313f562c3bc9581819d161d84566e706f3765249
|
||||
initial_ast: 64bbdbb801591bfdd54cf70019107a359ca2ef0d326be54c4d5622c848cb8de0
|
||||
constant_folded_ast: 64bbdbb801591bfdd54cf70019107a359ca2ef0d326be54c4d5622c848cb8de0
|
||||
unrolled_ast: 64bbdbb801591bfdd54cf70019107a359ca2ef0d326be54c4d5622c848cb8de0
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: 16910a94cf1f803ae6425ae6bee9422b01651c2c243b5e46807dc3191d169e64
|
||||
initial_ast: 46c9559d438edf0a3ea4939dc33277a04ea67b88424d5aeb56de436635fd83ca
|
||||
constant_folded_ast: 46c9559d438edf0a3ea4939dc33277a04ea67b88424d5aeb56de436635fd83ca
|
||||
unrolled_ast: 46c9559d438edf0a3ea4939dc33277a04ea67b88424d5aeb56de436635fd83ca
|
||||
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
outputs:
|
||||
- "Error [EPAR0370009]: unexpected string: expected 'formatted static_string', found 'hello'\n --> compiler-test:5:17\n |\n 5 | console.log(hello);\n | ^^^^^"
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: no input
|
||||
initial_ast: 8e1298749b5e6da6a3dcd789ad5a3a102952a00d88c38d4a693616679ef6d8d6
|
||||
constant_folded_ast: 8e1298749b5e6da6a3dcd789ad5a3a102952a00d88c38d4a693616679ef6d8d6
|
||||
unrolled_ast: 8e1298749b5e6da6a3dcd789ad5a3a102952a00d88c38d4a693616679ef6d8d6
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: no input
|
||||
initial_ast: e72f4854cb2c9ea3063fee92b826df43185c6a7a0a33f4fe6d24adc0c3dd8367
|
||||
constant_folded_ast: e72f4854cb2c9ea3063fee92b826df43185c6a7a0a33f4fe6d24adc0c3dd8367
|
||||
unrolled_ast: e72f4854cb2c9ea3063fee92b826df43185c6a7a0a33f4fe6d24adc0c3dd8367
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: no input
|
||||
initial_ast: 76aa1559acd72ebe4cf473f29efb52b9196776dd8bf19e1eb936f86eae7c26ed
|
||||
constant_folded_ast: 76aa1559acd72ebe4cf473f29efb52b9196776dd8bf19e1eb936f86eae7c26ed
|
||||
unrolled_ast: 76aa1559acd72ebe4cf473f29efb52b9196776dd8bf19e1eb936f86eae7c26ed
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: b649852fa2fd7eda05bd0ba261f01dcee93b6b825d5d30fddb8dd5c5710081ca
|
||||
initial_ast: 6b8b967664dbbb3e22420516aeac72957bf62b07a87851cf7ba803aac76fb752
|
||||
constant_folded_ast: 6b8b967664dbbb3e22420516aeac72957bf62b07a87851cf7ba803aac76fb752
|
||||
unrolled_ast: 6b8b967664dbbb3e22420516aeac72957bf62b07a87851cf7ba803aac76fb752
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: 3f35e74d282a1e5281e7f283d1e572a3dc75dea1a5ef1a0f8c7f46412ef946a7
|
||||
initial_ast: 9ac9a6615a1b0a46478b319e69f84de3a9a39123ddf9c8c7009931d7319967fc
|
||||
constant_folded_ast: 9ac9a6615a1b0a46478b319e69f84de3a9a39123ddf9c8c7009931d7319967fc
|
||||
unrolled_ast: 9ac9a6615a1b0a46478b319e69f84de3a9a39123ddf9c8c7009931d7319967fc
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: 4e3882d83c8044e40258f8414966b09c715b00e08bc3383030cecf2c4a825c60
|
||||
initial_ast: 78cd624d5a41679923d1802a284924d1f2de370a6ab422f1f9b04096707c8731
|
||||
constant_folded_ast: 78cd624d5a41679923d1802a284924d1f2de370a6ab422f1f9b04096707c8731
|
||||
unrolled_ast: 78cd624d5a41679923d1802a284924d1f2de370a6ab422f1f9b04096707c8731
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: eeba130bda3ee24f2a4bf92f67fb555ab849173910a647096e28729c2ebd71c2
|
||||
initial_ast: 460afe0b1aaa06f664fcee198f09df7295b79e5abe384748ac533a1196b38e90
|
||||
constant_folded_ast: 460afe0b1aaa06f664fcee198f09df7295b79e5abe384748ac533a1196b38e90
|
||||
unrolled_ast: 460afe0b1aaa06f664fcee198f09df7295b79e5abe384748ac533a1196b38e90
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: 3a510480221eb323713b4b10cc374ba357f130e8ac2b07bf1c69ad5d8c936f12
|
||||
initial_ast: 103c76ecc5358ae585e4cea32287890acfafc3fcbe53e5c6326b5750eafedbe7
|
||||
unrolled_ast: 103c76ecc5358ae585e4cea32287890acfafc3fcbe53e5c6326b5750eafedbe7
|
||||
constant_folded_ast: 9a34bff2ff62d6d72641f278b49a76abfb4e989041ed51a6c70de21e8c1766fa
|
||||
unrolled_ast: 9a34bff2ff62d6d72641f278b49a76abfb4e989041ed51a6c70de21e8c1766fa
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: 3f35e74d282a1e5281e7f283d1e572a3dc75dea1a5ef1a0f8c7f46412ef946a7
|
||||
initial_ast: 214befce37c1b0c1be25f614a3d928bae22f6d1dc518288b7ed4d007eddec2a7
|
||||
constant_folded_ast: 214befce37c1b0c1be25f614a3d928bae22f6d1dc518288b7ed4d007eddec2a7
|
||||
unrolled_ast: 214befce37c1b0c1be25f614a3d928bae22f6d1dc518288b7ed4d007eddec2a7
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: 9206742d7f18345efbd4d9077cd1aca0855d43a2436be0697ec22954650e3737
|
||||
initial_ast: 30a95deb7c12861dc98cbed1fb9ba37af688ad23504ac80bfedb74d00bcb1d32
|
||||
constant_folded_ast: 30a95deb7c12861dc98cbed1fb9ba37af688ad23504ac80bfedb74d00bcb1d32
|
||||
unrolled_ast: 30a95deb7c12861dc98cbed1fb9ba37af688ad23504ac80bfedb74d00bcb1d32
|
||||
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
outputs:
|
||||
- "Error [EPAR0370005]: expected -> -- found '{'\n --> compiler-test:3:17\n |\n 3 | function main() {\n | ^"
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: 047866515f4dc74cd9966242734984b53e72f87afc21f7171b118e6defa1f166
|
||||
initial_ast: 17aa90c54b70219cdff169e7ed82be28aea9c01dc2067908326c1fa384b83a0a
|
||||
constant_folded_ast: 17aa90c54b70219cdff169e7ed82be28aea9c01dc2067908326c1fa384b83a0a
|
||||
unrolled_ast: 17aa90c54b70219cdff169e7ed82be28aea9c01dc2067908326c1fa384b83a0a
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: 5e0a61d909d2e94dfbc95775e4c5c356adb61375ceef2d583a5ab927b3b6342e
|
||||
initial_ast: f5bdcda30d93281577f0a33daf097e79dd014e0e4bd4cbddfa48ff5f03d2bfd6
|
||||
constant_folded_ast: f5bdcda30d93281577f0a33daf097e79dd014e0e4bd4cbddfa48ff5f03d2bfd6
|
||||
unrolled_ast: f5bdcda30d93281577f0a33daf097e79dd014e0e4bd4cbddfa48ff5f03d2bfd6
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: 4e3882d83c8044e40258f8414966b09c715b00e08bc3383030cecf2c4a825c60
|
||||
initial_ast: c725f6542c21f1324498289b9496365219fc1dd662af5767d36455751ceb7f95
|
||||
constant_folded_ast: c725f6542c21f1324498289b9496365219fc1dd662af5767d36455751ceb7f95
|
||||
unrolled_ast: c725f6542c21f1324498289b9496365219fc1dd662af5767d36455751ceb7f95
|
||||
|
@ -5,4 +5,5 @@ outputs:
|
||||
- output:
|
||||
- initial_input_ast: e19dcac0064fed4ec8293b9b40ec70cb94b5fdb05f1081fc29f46a023bf79b09
|
||||
initial_ast: 227822368d014c2dc16897037981786cba91cade824469e49792f12638e8ce6c
|
||||
constant_folded_ast: 227822368d014c2dc16897037981786cba91cade824469e49792f12638e8ce6c
|
||||
unrolled_ast: 227822368d014c2dc16897037981786cba91cade824469e49792f12638e8ce6c
|
||||
|
9
tests/expectations/compiler/compiler/flatten/assign.out
Normal file
9
tests/expectations/compiler/compiler/flatten/assign.out
Normal file
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: aa1393713caf2f1e672eeb97c72cbd0a87018e9850e617b8d89b007846ca6ce5
|
||||
initial_ast: 8d9564fedf33a2eadd21f420ca6e18b9a414581b013a921d5fe1c1c2089988d1
|
||||
constant_folded_ast: 8d9564fedf33a2eadd21f420ca6e18b9a414581b013a921d5fe1c1c2089988d1
|
||||
unrolled_ast: 8d9564fedf33a2eadd21f420ca6e18b9a414581b013a921d5fe1c1c2089988d1
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
outputs:
|
||||
- "Error [ETYC0372002]: Cannot assign a non-const or invalid expression `x` to const variable `a`\n --> compiler-test:4:5\n |\n 4 | const a: u8 = x;\n | ^^^^^^^^^^^^^^^\nError [ETYC0372002]: Cannot assign a non-const or invalid expression `a` to const variable `b`\n --> compiler-test:5:5\n |\n 5 | const b: u8 = a;\n | ^^^^^^^^^^^^^^^\nError [ETYC0372002]: Cannot assign a non-const or invalid expression `c` to const variable `d`\n --> compiler-test:7:5\n |\n 7 | const d: u8 = c;\n | ^^^^^^^^^^^^^^^\n"
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: fbdd388a8095623e72c4ce8a7bc5e19774b53bbb31de78e54a1e6f0ae5fcff8b
|
||||
initial_ast: 78c5b35c7c92a00a19fb75451f2404bd57fbd1c7bbefe85d30078737bcb9c0f9
|
||||
constant_folded_ast: 12320274054f97f7148f07e2afa9e6ad88a388affc6dadadba903c39c60fdd0f
|
||||
unrolled_ast: 12320274054f97f7148f07e2afa9e6ad88a388affc6dadadba903c39c60fdd0f
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 8eb7f0df66ff4dc7e3669b18b7e91fb87cb01abff7e339dfb7b3f7700a8fa70d
|
||||
initial_ast: f771d19467be95511d4bbfafe8ebf8b3591cdb71ff93742d8c9532dbe6592ca5
|
||||
constant_folded_ast: 1623fe4dfb7fdb0c283bed338353bebe8c8521742534939410666b5f029b5280
|
||||
unrolled_ast: 1623fe4dfb7fdb0c283bed338353bebe8c8521742534939410666b5f029b5280
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: d047433f5a26031a57c3e113c73a034807464d506c1ed098fe11819708b5008a
|
||||
initial_ast: 36bac900131a18faf424eaac5e38c20210ee0fa2b0d8aff331b74b5b72d22d10
|
||||
constant_folded_ast: dc057aab5e3aaeca343cb62e95db2c893b863280a9e52d3857e6cb02ad9e43cf
|
||||
unrolled_ast: dc057aab5e3aaeca343cb62e95db2c893b863280a9e52d3857e6cb02ad9e43cf
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: c801c38dfba6c8161644a3854b966e539ed442a7726ddae0fc86f6fb7e9eb437
|
||||
initial_ast: 1339005912d2fded2688265d3ef9335cb22735cba168c911e6f64a97f5fa2a61
|
||||
constant_folded_ast: 1339005912d2fded2688265d3ef9335cb22735cba168c911e6f64a97f5fa2a61
|
||||
unrolled_ast: 1339005912d2fded2688265d3ef9335cb22735cba168c911e6f64a97f5fa2a61
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 9989b3703bf23e111c5392da92a8c3d682f21bebd0c941c3ca3b603431539575
|
||||
initial_ast: 6cd09ef25f28c8d60cfccbc4c8f5383edf6a6730f795a74ed2dabe2b0fd161f2
|
||||
constant_folded_ast: 6cd09ef25f28c8d60cfccbc4c8f5383edf6a6730f795a74ed2dabe2b0fd161f2
|
||||
unrolled_ast: 6cd09ef25f28c8d60cfccbc4c8f5383edf6a6730f795a74ed2dabe2b0fd161f2
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 460cec1fe1d74ae45bf7936fc05048ba2c3e2d98635da6aa8101ff7f19563222
|
||||
initial_ast: 12bac85cbc02dece3da96d81edaf858e71175768c91a2fec4383b566e1aed95f
|
||||
constant_folded_ast: 12bac85cbc02dece3da96d81edaf858e71175768c91a2fec4383b566e1aed95f
|
||||
unrolled_ast: 12bac85cbc02dece3da96d81edaf858e71175768c91a2fec4383b566e1aed95f
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 6c14c3195b124d9db01f93fe6ec77c8f46d4c38abc9a20fb296bc433a24a603f
|
||||
initial_ast: 19d9b5768a82022f235d06d714bbfd7e2b7e8cfb773aa7f3e973411b564335e5
|
||||
constant_folded_ast: bc66dd7ebe81ba526ca95cc07099dc3a925be1cefe9e2891b0283551ed5faab6
|
||||
unrolled_ast: 0c64e060f777b8e2c275a34838b563255250f3b4bb2740f740304f383fed1962
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: f8862af7c103f22d2472831008152f66745e2fdb6704e06bc52c0074e220a541
|
||||
initial_ast: 1f7da4c6e31dc7d2b1b6f621ee4fb0091e62937bdc0b6ee549cab103ddb21251
|
||||
constant_folded_ast: 1bc99df60fde32d0f54c3c74c870497934c3c5bd61fc9f97f03588917199c329
|
||||
unrolled_ast: 1bc99df60fde32d0f54c3c74c870497934c3c5bd61fc9f97f03588917199c329
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: c1de79b7d7476c0f412d4752336a205e3b95cb0b5078c607f20ef3a0d6b557dc
|
||||
initial_ast: 33a43b8f1c0e83a491689bc83479bf05d8ad87e672767bc3b19005005dceebf9
|
||||
constant_folded_ast: 8d2157cf0c9541750203d9e592eb70906ad5a11a5ad0921d39b956a0866ac4cf
|
||||
unrolled_ast: 8d2157cf0c9541750203d9e592eb70906ad5a11a5ad0921d39b956a0866ac4cf
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: e4bd5dc9546edb681355548f04e79ff9195950da250d7972ef47bc412d19fa4d
|
||||
initial_ast: 14b6a76da4a1849454c659edf93e47aa7dcda3ac4894a23d32783799583c14af
|
||||
constant_folded_ast: 13235453e4efb0d7e1ba77203521c556af439560b2cd4a3ce831ebfdff847794
|
||||
unrolled_ast: 13235453e4efb0d7e1ba77203521c556af439560b2cd4a3ce831ebfdff847794
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 439b0eab6d1265f8f575944aaf716b5990b03cb1d7d40b414f85e56f4ba219f1
|
||||
initial_ast: 58b375e52ff9e1d18562fb339b9633adc99bbdec885d3ebe6ebefba4c045ccc9
|
||||
constant_folded_ast: 53df862f4d699d3c1e892edc0307279e39823cd7dee2e2c95cf21f9f6449a799
|
||||
unrolled_ast: 53df862f4d699d3c1e892edc0307279e39823cd7dee2e2c95cf21f9f6449a799
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: f2088760f50db42a0b79700cf60136d9b873cacc881d28ebde3051723107f4b4
|
||||
initial_ast: 4c4f12d430cf94a04004a0d3aa5e9f05cf978f74201180798af3cb2d49354397
|
||||
constant_folded_ast: d40dc53cee17221a74777cb78fe3ef0f9ee9eb54598a60353d636f2cf56398dd
|
||||
unrolled_ast: d40dc53cee17221a74777cb78fe3ef0f9ee9eb54598a60353d636f2cf56398dd
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 98a0c6730e1741bc68f9ac19cc19c2857f3b9296a83e04f289d8ab77fee9f826
|
||||
initial_ast: 487e31705e8b3404bf82e5ea069a9b2f69a61003ce08651bd43004ca8b51d4e0
|
||||
constant_folded_ast: fd83c8e75e85ba62418db26328814445a164b678427f94059303e6c2e220d043
|
||||
unrolled_ast: fd83c8e75e85ba62418db26328814445a164b678427f94059303e6c2e220d043
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 8bd35fbbb74cac8e7b66bdb824ebee962cc0a6a870a03db795a6a677eb278af0
|
||||
initial_ast: 72f372106d7fc1dcfc72f1a26115af3e303ba1fb9f95e89a2317515abfc47e74
|
||||
constant_folded_ast: 2c1626eb2a7a8e47913e42184e22ed21358b4c5f42b9805f690c95cfc24f7ae2
|
||||
unrolled_ast: f9f9e7d1241efa0d292a48bf47af308c5fafddcda7e2eb251a56d1867be22d51
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: e9661641ab223bf1f21ae2693cbac83acab8e1377d1448da02aedff1d3988cb6
|
||||
initial_ast: e478d59175bb8d465bc952578ac5e1e8e3b7965fb66fd475ce75bc7daf685472
|
||||
constant_folded_ast: 0c12d98715d47ec1010814359d7f08160b60faff866db576287a4013e413b5bd
|
||||
unrolled_ast: 2f8e43fdd38916581a5d8119f7dcdeb7d6d1105b015aaa314afa808f6efcc14b
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 86072b801b459bc2058534dee98107664fc7bb5d094f2691e73f4dbd6162932e
|
||||
initial_ast: 8036f15e1544a127b61c1dbdb8fbae15436beb2ffba0d0ff9cf7dbad9c1699c1
|
||||
constant_folded_ast: 23bc06ce8a2740cf3d22eee0643165c03b5bab84f5213b82bd2b28849eef22f4
|
||||
unrolled_ast: 23bc06ce8a2740cf3d22eee0643165c03b5bab84f5213b82bd2b28849eef22f4
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: f54ec02da0be149dbd0d82b388e115439d6ddabbff122997a484edd0f19b9ee1
|
||||
initial_ast: e3923bb6d83d8fe026f0ddf66f9a15bdc4dd89dbad31205c82332968cf53a035
|
||||
constant_folded_ast: e3923bb6d83d8fe026f0ddf66f9a15bdc4dd89dbad31205c82332968cf53a035
|
||||
unrolled_ast: e3923bb6d83d8fe026f0ddf66f9a15bdc4dd89dbad31205c82332968cf53a035
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 102d048c96a62736c207c6d1cf4acd3e3f212607dccb096f202b51906557b2d4
|
||||
initial_ast: 5480a4b91da06465deb09dfbd395a3927173bb0d8aae8f559174d6d3cac0462f
|
||||
constant_folded_ast: d54decd01500417daa3dc4a2885b64f0db5f1319c2e7e974ce888c57714107cc
|
||||
unrolled_ast: b158b02ffe4b678b4f97ce793f907a632273b3a4921a0211f44317be03004d9f
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 00c1656db8910688169d943d9073a7322a50dfaa0f79c8ffe92d1371d159c085
|
||||
initial_ast: 8c2ef5f6d4351b69ea00ab064d509b8f503ce6f418bd175b09c1617894164023
|
||||
constant_folded_ast: c93a71f11830257814fb658d45da2ac8d3c1353777d093c9f961781c5a8b5095
|
||||
unrolled_ast: 7ac2cc6848d435cdf485b33abf15d0377f9195ba4acdbe122ea7686044c0df46
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 98a0c6730e1741bc68f9ac19cc19c2857f3b9296a83e04f289d8ab77fee9f826
|
||||
initial_ast: a61288b2d5f6e59041aa78c9b6ac3409a66b4980562e0147c2f5bd4091e5c789
|
||||
constant_folded_ast: a61288b2d5f6e59041aa78c9b6ac3409a66b4980562e0147c2f5bd4091e5c789
|
||||
unrolled_ast: 99c762854f8f83fe86580ef43128b015e5249d2f1f463f6941d9ead01ad7a319
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 65197bd6b7f4b0fd5bf7c8544d5c51690b9eda5faee4ae7372b7e9fa23a54d82
|
||||
initial_ast: e93a961e1d81d4113d0df37da797494148a3c9e9155c1f8bafce593fa8e89ee4
|
||||
constant_folded_ast: e93a961e1d81d4113d0df37da797494148a3c9e9155c1f8bafce593fa8e89ee4
|
||||
unrolled_ast: 36bfb88c48f98ada3fa71a7608eb27fba745a5320d54a2b7172cf8c804d5af6b
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: d5d93e17650329b540e070271717291170baaefdbbc4b7b1802a92958b43aa8d
|
||||
initial_ast: 159fa5472193b35fc8314403d95620a5fe3e0eabdf3d9d2e2900df9c24afd5f7
|
||||
constant_folded_ast: 23df9d08577067a17dcaecc9b1c2e71176a1293bb7affe09f3b96dd8a42e1cb9
|
||||
unrolled_ast: b90b5737417e6d3ee034b1841efbad3619f9c955a857fb9fbb0b1c2138843208
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
outputs:
|
||||
- "Error [ETYC0372007]: Expected one type from `bool`, but got `u8`\n --> compiler-test:5:12\n |\n 5 | return d == 2u8;\n | ^^^^^^^^\n"
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 883e0237abced86de97f7078e0feffee48141540983630fefc1f6ce725076407
|
||||
initial_ast: ad9fe52271af7ff35574081d429295bb061419bdede30cd062161a89d866e171
|
||||
constant_folded_ast: ad9fe52271af7ff35574081d429295bb061419bdede30cd062161a89d866e171
|
||||
unrolled_ast: ad9fe52271af7ff35574081d429295bb061419bdede30cd062161a89d866e171
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 287bb895150f2205c795ef5694f3e93cfd799df072e17b8bd1b7b0cd46322aa2
|
||||
initial_ast: f6216d2c65acf02b0a14e02c458e478f6c0a2e87198dc7508f17c4a3a23ee283
|
||||
constant_folded_ast: f0b851db03360cd7ca4802d1aa26885f4c488d0d2f13fd58e55d598f21768a4d
|
||||
unrolled_ast: f0b851db03360cd7ca4802d1aa26885f4c488d0d2f13fd58e55d598f21768a4d
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: no input
|
||||
initial_ast: f39b6c0e43864f8d9aa219b3b9e1f91ee51f913e325f61646056f3ecd2493827
|
||||
constant_folded_ast: 1782a73bf2c541c6a1ddcbf3bfab12c7ddcbd452214473b16796af9047ff1454
|
||||
unrolled_ast: 1782a73bf2c541c6a1ddcbf3bfab12c7ddcbd452214473b16796af9047ff1454
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: d5d93e17650329b540e070271717291170baaefdbbc4b7b1802a92958b43aa8d
|
||||
initial_ast: eb9588066d0ce6c75fdedd86ae250d33c82cbb0a5dba868a0012629da71a087b
|
||||
constant_folded_ast: a14b284eab513b2b6d535c138581aa6d5556037fdbb1bf5b264a46d512adc15a
|
||||
unrolled_ast: a14b284eab513b2b6d535c138581aa6d5556037fdbb1bf5b264a46d512adc15a
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 56f12dac6f01bb804ca9966d8ab3cb6520f82c68f6f83904ddb6a3f5344c28f9
|
||||
initial_ast: 19661d319b6a5344a669cbf0b1b417a6553afcbcd7354df6bcfc0acb485c1639
|
||||
constant_folded_ast: 5644de48b4487d7f41b78f838602826321a2979842b7324c874394fa22524e7b
|
||||
unrolled_ast: 5644de48b4487d7f41b78f838602826321a2979842b7324c874394fa22524e7b
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: df15b144128af8f324bcff194ba721c0a103b5ba6cd782f22a1010527714adf0
|
||||
initial_ast: ad743e3477db01f0b6a3b7326d9c8a82234fb109e288ea1f3cb08ff9dc08284f
|
||||
constant_folded_ast: 49eb73a77ddad4cc1c18f4dcb9731ea5a44aca0ef48efd14b92368a0d106afa8
|
||||
unrolled_ast: 49eb73a77ddad4cc1c18f4dcb9731ea5a44aca0ef48efd14b92368a0d106afa8
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 3a5cdc075eb89f819cdcedb9ad101991ec22f92ff92a2143c37d4df3b883d904
|
||||
initial_ast: 40b52c1869daa7087656b29db3e836398f0b04cc8f7c5df0d42e65fb48dbba80
|
||||
constant_folded_ast: 49eb73a77ddad4cc1c18f4dcb9731ea5a44aca0ef48efd14b92368a0d106afa8
|
||||
unrolled_ast: 49eb73a77ddad4cc1c18f4dcb9731ea5a44aca0ef48efd14b92368a0d106afa8
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: f931c277a075a38f5db7dd0fece2ed216aad7db9cd3c0eb94b098d3b2a73e1a1
|
||||
initial_ast: 964d1c81ede76e5b084851dde3a939bdbacb6771f20eda299eab12265b56a74f
|
||||
constant_folded_ast: 964d1c81ede76e5b084851dde3a939bdbacb6771f20eda299eab12265b56a74f
|
||||
unrolled_ast: 964d1c81ede76e5b084851dde3a939bdbacb6771f20eda299eab12265b56a74f
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 94b9d2b0ee1ba69f9ab4ae607f6806e9ea4f609196bf1ec2c402251ac227afa1
|
||||
initial_ast: 8864b4a389a56c6ad230c67d34fe968bb47209a3aaf03e076f54caadf649221a
|
||||
constant_folded_ast: 8864b4a389a56c6ad230c67d34fe968bb47209a3aaf03e076f54caadf649221a
|
||||
unrolled_ast: 8864b4a389a56c6ad230c67d34fe968bb47209a3aaf03e076f54caadf649221a
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
outputs:
|
||||
- "Error [EFLA0373001]: The const operation `(neg -128i8` causes an overflow.\n --> compiler-test:1:1\n |\n 1 | \n | \n"
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 20cf180c204f60443f0c85bf796587115fe9ddc1ccc2f5926168b7b893b9e378
|
||||
initial_ast: 854aceeaa2e4f31ada9ac89b0477ea75345639b4ba0203d1106a5cc5d04c953d
|
||||
constant_folded_ast: 854aceeaa2e4f31ada9ac89b0477ea75345639b4ba0203d1106a5cc5d04c953d
|
||||
unrolled_ast: 367166e38186ce2dba371cf4d79e0949f0a3dc4d16a984cebaef14eaffab842a
|
9
tests/expectations/compiler/compiler/flatten/loop.out
Normal file
9
tests/expectations/compiler/compiler/flatten/loop.out
Normal file
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: ae09cd950e6161ba9d553d354ddb9934a79d0c219c1a78561596324b041ba8ef
|
||||
initial_ast: f63090c0f3549e01e424151865108da2ba57811c2b9b978ef62ac32f066b6688
|
||||
constant_folded_ast: e4235eeb633d1b5a5475ea1f3831ad7826a4e404598b57ade20fcaa02ef9dcb3
|
||||
unrolled_ast: 7d80880de07d3262dd5048ca5d91925ff8d9e1c9c98f0655bbeb3673bb34e77a
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Fail
|
||||
outputs:
|
||||
- "Error [ETYC0372002]: Cannot assign a non-const or invalid expression `a` to const variable `a`\n --> compiler-test:5:5\n |\n 5 | a = b;\n | ^^^^^\nError [ETYC0372002]: Cannot assign a non-const or invalid expression `i` to const variable `i`\n --> compiler-test:7:9\n |\n 7 | i = 1u32;\n | ^^^^^^^^\n"
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: 35f21cd1f54b9cad7f407ac6c73b110c8172c6cecb92b86d0c5d74c9bbb166f0
|
||||
initial_ast: 50621ac8e6fce4e48f48e78813bf0e9d90d206a04249454d263bd3917090c16c
|
||||
constant_folded_ast: 50621ac8e6fce4e48f48e78813bf0e9d90d206a04249454d263bd3917090c16c
|
||||
unrolled_ast: 5de99f12e83f2dfbbeaea82d03a6e8ebe9a9a8fd75e72197f700e7a87497ea63
|
@ -0,0 +1,9 @@
|
||||
---
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- output:
|
||||
- initial_input_ast: ef8a8facd01e34f76b7202f6de5e4cd6a3c5787dbbc200e1926096e477ad0f65
|
||||
initial_ast: dc972c6cd5d611c76b7f84234dfb9a9ef5c283e1d852c8b4922150735c33d389
|
||||
constant_folded_ast: dc972c6cd5d611c76b7f84234dfb9a9ef5c283e1d852c8b4922150735c33d389
|
||||
unrolled_ast: dc972c6cd5d611c76b7f84234dfb9a9ef5c283e1d852c8b4922150735c33d389
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user