units: Comment alloc feature

Add a comment to the `serde` module about why we have all the `alloc`
feature gating.

Done as part of #3556 - auditing the whole crate for use of `alloc`
feature.
This commit is contained in:
Tobin C. Harding 2024-11-22 10:42:17 +11:00
parent 0bff8d05fc
commit 17ca5018eb
No known key found for this signature in database
GPG Key ID: 40BF9E4C269D6607
1 changed files with 1 additions and 1 deletions

View File

@ -24,7 +24,7 @@ use core::fmt;
use serde::{Deserialize, Deserializer, Serialize, Serializer}; use serde::{Deserialize, Deserializer, Serialize, Serializer};
#[cfg(feature = "alloc")] #[cfg(feature = "alloc")] // This is because `to_float_in` uses `to_string`.
use super::Denomination; use super::Denomination;
use super::{Amount, ParseAmountError, SignedAmount}; use super::{Amount, ParseAmountError, SignedAmount};