Skip to main content

gobject_ast/model/expression/
update.rs

1use serde::Serialize;
2
3use crate::model::{Expression, SourceLocation, UpdateOp};
4
5#[derive(Debug, Clone, Serialize)]
6pub struct UpdateExpression {
7    pub operator: UpdateOp,
8    pub operand: Box<Expression>,
9    #[serde(skip_serializing_if = "std::ops::Not::not")]
10    pub is_prefix: bool, // true for ++x, false for x++
11    pub location: SourceLocation,
12}