rust/compiler/rustc_metadata/src
Nicholas Nethercote 2fef0a30ae Replace infallible name_or_empty methods with fallible name methods.
I'm removing empty identifiers everywhere, because in practice they
always mean "no identifier" rather than "empty identifier". (An empty
identifier is impossible.) It's better to use `Option` to mean "no
identifier" because you then can't forget about the "no identifier"
possibility.

Some specifics:
- When testing an attribute for a single name, the commit uses the
  `has_name` method.
- When testing an attribute for multiple names, the commit uses the new
  `has_any_name` method.
- When using `match` on an attribute, the match arms now have `Some` on
  them.

In the tests, we now avoid printing empty identifiers by not printing
the identifier in the `error:` line at all, instead letting the carets
point out the problem.
2025-04-17 09:50:52 +10:00
..
rmeta Replace infallible name_or_empty methods with fallible name methods. 2025-04-17 09:50:52 +10:00
creader.rs Make LevelAndSource a struct 2025-04-03 09:17:55 +00:00
dependency_format.rs Support rmeta inputs for --crate-type=bin --emit=obj 2025-03-07 18:33:05 +01:00
errors.rs Add an error when full metadata was not found 2025-03-31 09:44:41 +02:00
foreign_modules.rs Move some Map methods onto TyCtxt. 2025-02-17 13:21:02 +11:00
fs.rs Store only a metadata stub into rlibs and dylibs with -Zembed-metadata=no 2025-03-31 09:44:41 +02:00
lib.rs Remove recursion_limit increases. 2025-04-02 16:25:27 +11:00
locator.rs Add an error when full metadata was not found 2025-03-31 09:44:41 +02:00
native_libs.rs Replace infallible name_or_empty methods with fallible name methods. 2025-04-17 09:50:52 +10:00