Skip to content

Commit 1d03fe5

Browse files
committed
Migrate the namespace_package example to a 'rust' dir
1 parent 6274354 commit 1d03fe5

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

examples/namespace_package/Cargo.toml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,18 @@ version = "0.1.0"
44
edition = "2018"
55

66
[lib]
7+
# When omitted, the name field will be assumed to have the same value as package.name
8+
# https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-name-field
79
crate-type = ["cdylib", "rlib"]
10+
path = "rust/lib.rs" # When omitted, the value of "src/lib.rs" is assumed
11+
# See https://doc.rust-lang.org/cargo/reference/cargo-targets.html#library
12+
#
13+
# If [lib] is not specified, but the file ``src/lib.rs`` exists,
14+
# you can also rely on an implicit definition which will behave similarly to:
15+
#
16+
# [lib]
17+
# name = <package.name>
18+
# path = "src/lib.rs"
819

920
[dependencies]
1021
pyo3 = { version = "0.19.2", features = ["extension-module"] }
File renamed without changes.

0 commit comments

Comments
 (0)