diff options
| author | mat <github@matdoes.dev> | 2022-06-25 14:25:56 -0500 |
|---|---|---|
| committer | mat <github@matdoes.dev> | 2022-06-25 14:25:56 -0500 |
| commit | c46eb556e2e7964f0709572a0151c181752c3182 (patch) | |
| tree | da65427d74aaa66e002385989faee04c7bac6cbd /azalea-protocol/src/lib.rs | |
| parent | 8755f18c2b0c11a51a81f60b5501d9d57d0c370e (diff) | |
| parent | 77980f0018eca3a192994021b76ad5d05bff88ea (diff) | |
| download | azalea-drasl-c46eb556e2e7964f0709572a0151c181752c3182.tar.xz | |
Merge branch 'main' into 1.19.1
Diffstat (limited to 'azalea-protocol/src/lib.rs')
| -rwxr-xr-x | azalea-protocol/src/lib.rs | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/azalea-protocol/src/lib.rs b/azalea-protocol/src/lib.rs index d7f75f00..b1d1a9c4 100755 --- a/azalea-protocol/src/lib.rs +++ b/azalea-protocol/src/lib.rs @@ -1,13 +1,11 @@ //! This lib is responsible for parsing Minecraft packets. -#![feature(min_specialization)] -#![feature(arbitrary_enum_discriminant)] - use std::net::IpAddr; use std::str::FromStr; +#[cfg(feature = "connecting")] pub mod connect; -pub mod mc_buf; +#[cfg(feature = "packets")] pub mod packets; pub mod read; pub mod resolver; @@ -43,6 +41,7 @@ impl<'a> TryFrom<&'a str> for ServerAddress { } } +#[cfg(feature = "connecting")] pub async fn connect(address: ServerAddress) -> Result<(), Box<dyn std::error::Error>> { let resolved_address = resolver::resolve_address(&address).await; println!("Resolved address: {:?}", resolved_address); |
