diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2022-08-23 19:16:47 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-23 19:16:47 +0000 |
commit | 825a44b40ce6cfa76470e53d0746b1e64b99ee5b (patch) | |
tree | 05ac7d0a80bd078e8563ae8649399acec8ccb8fd /gcc/rust/backend/rust-compile-expr.h | |
parent | 241fcaacf600fa4c149d30afa2cf1a42f57c9a0c (diff) | |
parent | 36a9255b1b6683bb060021c637997de396445049 (diff) | |
download | gcc-825a44b40ce6cfa76470e53d0746b1e64b99ee5b.zip gcc-825a44b40ce6cfa76470e53d0746b1e64b99ee5b.tar.gz gcc-825a44b40ce6cfa76470e53d0746b1e64b99ee5b.tar.bz2 |
Merge #1497
1497: Refactor our casts to follow the Rustc implemention r=philberty a=philberty
This gets rid of our old visitor system for cast type checking. Casts
depend on type coercions as they are meant to attempt a type coercion
before trying a simple cast. This explicitly defines the rules which should
be allowed for simple casts. In rustc they use match expressions to write
a list of casts which should not be allowed. We have likely missed some
rules of what should be allowed but this is at least the start of how
to implement this.
Fixes #1496
Co-authored-by: Philip Herron <philip.herron@embecosm.com>
Diffstat (limited to 'gcc/rust/backend/rust-compile-expr.h')
0 files changed, 0 insertions, 0 deletions