-
Notifications
You must be signed in to change notification settings - Fork 162
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
gccrs: [E0308] array misamatch types
gcc/rust/ChangeLog: * backend/rust-compile.cc (HIRCompileBase::verify_array_capacities): Added ErrorCode. gcc/testsuite/ChangeLog: * rust/compile/arrays2.rs: changed comment to pass testcase. Signed-off-by: Muhammad Mahad <mahadtxt@gmail.com>
- Loading branch information
1 parent
a584856
commit 67d1f4a
Showing
2 changed files
with
7 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
// { dg-additional-options "-w" } | ||
fn main() { | ||
let array: [i32; 5] = [1, 2, 3]; | ||
// { dg-error "expected an array with a fixed size of 5 elements, found one with 3 elements" "" { target *-*-* } .-1 } | ||
// { dg-error "mismatched types, expected an array with a fixed size of 5 elements, found one with 3 elements" "" { target *-*-* } .-1 } | ||
} |