Skip to content

regression: hashmap macro stuff #147971

@BoxyUwU

Description

@BoxyUwU
[INFO] [stdout] error[E0659]: `hash_map` is ambiguous
[INFO] [stdout]   --> src/bin/day02-1.rs:49:17
[INFO] [stdout]    |
[INFO] [stdout] 49 |                 hash_map!(
[INFO] [stdout]    |                 ^^^^^^^^ ambiguous name
[INFO] [stdout]    |
[INFO] [stdout]    = note: ambiguous because of a conflict between a name from a glob import and an outer scope during import or macro resolution
[INFO] [stdout]    = note: `hash_map` could refer to a macro from prelude
[INFO] [stdout] error[E0658]: use of unstable library feature `hash_map_macro`
[INFO] [stdout]  --> src/hash_map/cfg.rs:4:38
[INFO] [stdout]   |
[INFO] [stdout] 4 |     let my_map: HashMap<&str, i32> = hash_map!("a" => 1, "b" => 2);
[INFO] [stdout]   |                                      ^^^^^^^^
[INFO] [stdout]   |
[INFO] [stdout]   = note: see issue #144032 <https://github.com/rust-lang/rust/issues/144032> for more information

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-macrosArea: All kinds of macros (custom derive, macro_rules!, proc macros, ..)C-bugCategory: This is a bug.P-highHigh priorityT-compilerRelevant to the compiler team, which will review and decide on the PR/issue.T-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.regression-from-stable-to-betaPerformance or correctness regression from stable to beta.

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions