gnu/gcc/b80c154cf0fda31a6fa9ce85c60bfcb82966cd67 gccrs: typecheck: Special case builtin types when typechecking types.
Type definition conflicts are allowed in the case of builtin types. This is used in the
`core` crate to add some more functionality to the builtin types. The consequence of this
is that we need to special case the resolution of types in the case that their name could
refer to a module or to a builtin type.
gcc/rust/ChangeLog:
* typecheck/rust-hir-type-check-type.cc (TypeCheckType::resolve_root_path): Add
special casing for resolving to the builtin type definition if the found type
has the same name and is a module.
gcc/testsuite/ChangeLog:
* rust/compile/type-with-builtin-type-name.rs: New test.
2 files changed