Skip to content

Commit

Permalink
Fix typo.
Browse files Browse the repository at this point in the history
  • Loading branch information
otrho committed Oct 7, 2024
1 parent bfb31f7 commit 57c640f
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions pintc/src/error/compile_error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1467,13 +1467,13 @@ impl ReportableError for CompileError {
BadCastFrom { .. } => {
if cfg!(feature = "experimental-types") {
Some(
"casts may only be made from `bool`s,`int`s, and enuemration unions to `int`, \
"casts may only be made from `bool`s,`int`s, and enumeration unions to `int`, \
or from `int`s, `real`s, and enumeration unions to `real`"
.to_string()
)
} else {
Some(
"casts may only be made from `bool`s,`int`s, and enuemration unions to `int`"
"casts may only be made from `bool`s,`int`s, and enumeration unions to `int`"
.to_string()
)
}
Expand Down
6 changes: 3 additions & 3 deletions pintc/tests/evaluator/cast_error.pnt
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ const c = 44 as bool;
// typecheck_failure <<<
// invalid cast
// @33..48: illegal cast from `int[_]`
// casts may only be made from `bool`s,`int`s, and enuemration unions to `int`
// casts may only be made from `bool`s,`int`s, and enumeration unions to `int`
// invalid cast
// @10..21: illegal cast from `{int}`
// casts may only be made from `bool`s,`int`s, and enuemration unions to `int`
// casts may only be made from `bool`s,`int`s, and enumeration unions to `int`
// invalid cast
// @60..70: illegal cast from `int`
// casts may only be made from `bool`s,`int`s, and enuemration unions to `int`
// casts may only be made from `bool`s,`int`s, and enumeration unions to `int`
// >>>
6 changes: 3 additions & 3 deletions pintc/tests/experimental/cast_error.pnt
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ const c = 44 as bool;
// typecheck_failure <<<
// invalid cast
// @33..48: illegal cast from `int[_]`
// casts may only be made from `bool`s,`int`s, and enuemration unions to `int`, or from `int`s, `real`s, and enumeration unions to `real`
// casts may only be made from `bool`s,`int`s, and enumeration unions to `int`, or from `int`s, `real`s, and enumeration unions to `real`
// invalid cast
// @10..21: illegal cast from `{int}`
// casts may only be made from `bool`s,`int`s, and enuemration unions to `int`, or from `int`s, `real`s, and enumeration unions to `real`
// casts may only be made from `bool`s,`int`s, and enumeration unions to `int`, or from `int`s, `real`s, and enumeration unions to `real`
// invalid cast
// @60..70: illegal cast from `int`
// casts may only be made from `bool`s,`int`s, and enuemration unions to `int`, or from `int`s, `real`s, and enumeration unions to `real`
// casts may only be made from `bool`s,`int`s, and enumeration unions to `int`, or from `int`s, `real`s, and enumeration unions to `real`
// >>>
2 changes: 1 addition & 1 deletion pintc/tests/unions/bad_union_used_as_enum.pnt
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ predicate Foo {
// typecheck_failure <<<
// invalid cast
// @73..84: illegal cast from `::U`
// casts may only be made from `bool`s,`int`s, and enuemration unions to `int`
// casts may only be made from `bool`s,`int`s, and enumeration unions to `int`
// invalid array range type ::U
// @54..55: array access must be of type `int` or enumeration `union`
// found range type `::U`
Expand Down

0 comments on commit 57c640f

Please sign in to comment.