Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(gcore): add proper conditional compilation for stack_debug macro #4374

Merged
merged 1 commit into from
Dec 4, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 7 additions & 5 deletions gcore/src/utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,14 @@ impl AsRawPtr for ReservationId {}

/// Extensions for additional features.
pub mod ext {
use crate::stack_buffer;
use core::{
fmt::{self, Write as _},
mem::MaybeUninit,
#[cfg(any(feature = "debug", debug_assertions))]
use {
crate::stack_buffer::{self, MAX_BUFFER_SIZE},
core::{
fmt::{self, Write as _},
mem::MaybeUninit,
},
};
use gear_stack_buffer::MAX_BUFFER_SIZE;

/// Add a `data` string to the debug log.
///
Expand Down
Loading