mirror of
https://github.com/RustPython/Parser.git
synced 2025-07-25 22:14:25 +00:00
Add optional serde dependency
This commit is contained in:
parent
969ea23d67
commit
713dd2b91e
3 changed files with 7 additions and 0 deletions
|
@ -1,5 +1,9 @@
|
|||
#[cfg(feature = "serde")]
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
/// Sourcecode location.
|
||||
#[derive(Clone, Copy, Debug, PartialEq, Eq, PartialOrd, Ord)]
|
||||
#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
|
||||
pub struct Location {
|
||||
pub(super) row: u32,
|
||||
pub(super) column: u32,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue