Skip to content

Commit 9d03b66

Browse files
committed
Fix failing proc macros when depending on bevy through dev and normal dependencies.
1 parent ea57841 commit 9d03b66

File tree

3 files changed

+7
-3
lines changed

3 files changed

+7
-3
lines changed

crates/bevy_macro_utils/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ keywords = ["bevy"]
1212
syn = "2.0"
1313
quote = "1.0"
1414
proc-macro2 = "1.0"
15-
cargo-manifest-proc-macros = "0.3.3"
15+
cargo-manifest-proc-macros = "0.3.4"
1616

1717
[lints]
1818
workspace = true

crates/bevy_macro_utils/src/bevy_manifest.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,7 @@ impl BevyManifest {
4848
/// Returns the path for the crate with the given name.
4949
pub fn get_path(&self, name: &str) -> syn::Path {
5050
self.maybe_get_path(name)
51-
//.expect("Failed to get path for crate")
52-
.unwrap_or_else(|_err| Self::parse_str(name))
51+
.expect("Failed to get path for crate")
5352
}
5453

5554
/// Attempt to parse the provided [path](str) as a [syntax tree node](syn::parse::Parse)

tests-integration/simple-ecs-test/Cargo.toml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,10 @@
22
name = "simple-ecs-test"
33
edition = "2021"
44

5+
# We depend on bevy in both normal and dev dependencies to verify that the proc macros still work.
6+
57
[dependencies]
68
bevy = { path = "../../" }
9+
10+
[dev-dependencies]
11+
bevy = { path = "../../" }

0 commit comments

Comments
 (0)