Skip to content

Commit

Permalink
Make span pub field
Browse files Browse the repository at this point in the history
  • Loading branch information
flyingsilverfin committed Jan 30, 2025
1 parent 03b4c45 commit ea9244f
Show file tree
Hide file tree
Showing 27 changed files with 91 additions and 91 deletions.
22 changes: 11 additions & 11 deletions rust/annotation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ impl fmt::Display for Annotation {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Abstract {
span: Option<Span>,
pub span: Option<Span>,
}

impl Abstract {
Expand All @@ -88,7 +88,7 @@ impl fmt::Display for Abstract {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Cardinality {
span: Option<Span>,
pub span: Option<Span>,
pub range: CardinalityRange,
}

Expand Down Expand Up @@ -128,7 +128,7 @@ impl fmt::Display for CardinalityRange {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Cascade {
span: Option<Span>,
pub span: Option<Span>,
}

impl Cascade {
Expand All @@ -151,7 +151,7 @@ impl fmt::Display for Cascade {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Distinct {
span: Option<Span>,
pub span: Option<Span>,
}

impl Distinct {
Expand All @@ -174,7 +174,7 @@ impl fmt::Display for Distinct {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Independent {
span: Option<Span>,
pub span: Option<Span>,
}

impl Independent {
Expand All @@ -197,7 +197,7 @@ impl fmt::Display for Independent {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Key {
span: Option<Span>,
pub span: Option<Span>,
}

impl Key {
Expand All @@ -220,7 +220,7 @@ impl fmt::Display for Key {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Range {
span: Option<Span>,
pub span: Option<Span>,
pub min: Option<Literal>,
pub max: Option<Literal>,
}
Expand Down Expand Up @@ -254,7 +254,7 @@ impl fmt::Display for Range {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Regex {
span: Option<Span>,
pub span: Option<Span>,
pub regex: StringLiteral,
}

Expand All @@ -278,7 +278,7 @@ impl fmt::Display for Regex {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Subkey {
span: Option<Span>,
pub span: Option<Span>,
pub ident: Identifier,
}

Expand All @@ -302,7 +302,7 @@ impl fmt::Display for Subkey {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Unique {
span: Option<Span>,
pub span: Option<Span>,
}

impl Unique {
Expand All @@ -325,7 +325,7 @@ impl fmt::Display for Unique {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Values {
span: Option<Span>,
pub span: Option<Span>,
pub values: Vec<Literal>,
}

Expand Down
2 changes: 1 addition & 1 deletion rust/common/identifier.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ use crate::{

#[derive(Debug, Clone, Eq, PartialEq, Hash)]
pub struct Identifier {
span: Option<Span>,
pub span: Option<Span>,
ident: String,
}

Expand Down
12 changes: 6 additions & 6 deletions rust/expression/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ use crate::{

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct BuiltinFunctionName {
span: Option<Span>,
pub span: Option<Span>,
pub token: token::Function,
}

Expand Down Expand Up @@ -72,7 +72,7 @@ impl fmt::Display for FunctionName {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct FunctionCall {
span: Option<Span>,
pub span: Option<Span>,
pub name: FunctionName,
pub args: Vec<Expression>,
}
Expand Down Expand Up @@ -133,7 +133,7 @@ impl fmt::Display for Operation {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Paren {
span: Option<Span>,
pub span: Option<Span>,
pub inner: Expression,
}

Expand All @@ -159,7 +159,7 @@ impl fmt::Display for Paren {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct ListIndex {
span: Option<Span>,
pub span: Option<Span>,
pub variable: Variable,
pub index: Expression,
}
Expand All @@ -186,7 +186,7 @@ impl fmt::Display for ListIndex {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct List {
span: Option<Span>,
pub span: Option<Span>,
pub items: Vec<Expression>,
}

Expand Down Expand Up @@ -215,7 +215,7 @@ impl fmt::Display for List {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct ListIndexRange {
span: Option<Span>,
pub span: Option<Span>,
pub var: Variable,
pub from: Expression,
pub to: Expression,
Expand Down
8 changes: 4 additions & 4 deletions rust/pattern/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ use crate::{

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Conjunction {
span: Option<Span>,
pub span: Option<Span>,
pub patterns: Vec<Pattern>,
}

Expand Down Expand Up @@ -43,7 +43,7 @@ impl fmt::Display for Conjunction {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Negation {
span: Option<Span>,
pub span: Option<Span>,
pub patterns: Vec<Pattern>,
}

Expand Down Expand Up @@ -74,7 +74,7 @@ impl fmt::Display for Negation {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Optional {
span: Option<Span>,
pub span: Option<Span>,
pub patterns: Vec<Pattern>,
}

Expand Down Expand Up @@ -105,7 +105,7 @@ impl fmt::Display for Optional {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Disjunction {
span: Option<Span>,
pub span: Option<Span>,
pub branches: Vec<Vec<Pattern>>,
}

Expand Down
4 changes: 2 additions & 2 deletions rust/query/pipeline/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ pub mod stage;

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Preamble {
span: Option<Span>,
pub span: Option<Span>,
pub function: definable::Function,
}

Expand All @@ -45,7 +45,7 @@ impl fmt::Display for Preamble {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Pipeline {
span: Option<Span>,
pub span: Option<Span>,
pub preambles: Vec<Preamble>,
pub stages: Vec<Stage>,
}
Expand Down
4 changes: 2 additions & 2 deletions rust/query/pipeline/stage/delete.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ use crate::{

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Delete {
span: Option<Span>,
pub span: Option<Span>,
pub deletables: Vec<Deletable>,
}

Expand Down Expand Up @@ -60,7 +60,7 @@ impl fmt::Display for Delete {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Deletable {
span: Option<Span>,
pub span: Option<Span>,
pub kind: DeletableKind,
}

Expand Down
2 changes: 1 addition & 1 deletion rust/query/pipeline/stage/insert.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ use crate::{

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Insert {
span: Option<Span>,
pub span: Option<Span>,
pub statements: Vec<Statement>,
}

Expand Down
2 changes: 1 addition & 1 deletion rust/query/pipeline/stage/match_.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ use crate::{

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Match {
span: Option<Span>,
pub span: Option<Span>,
pub patterns: Vec<Pattern>,
}

Expand Down
12 changes: 6 additions & 6 deletions rust/query/pipeline/stage/modifier.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ use crate::{

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct OrderedVariable {
span: Option<Span>,
pub span: Option<Span>,
pub variable: Variable,
pub ordering: Option<Order>,
}
Expand Down Expand Up @@ -51,7 +51,7 @@ impl fmt::Display for OrderedVariable {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Sort {
span: Option<Span>,
pub span: Option<Span>,
pub ordered_variables: Vec<OrderedVariable>,
}

Expand Down Expand Up @@ -80,7 +80,7 @@ impl fmt::Display for Sort {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Select {
span: Option<Span>,
pub span: Option<Span>,
pub variables: Vec<Variable>,
}

Expand Down Expand Up @@ -109,7 +109,7 @@ impl fmt::Display for Select {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Offset {
span: Option<Span>,
pub span: Option<Span>,
pub offset: IntegerLiteral,
}

Expand All @@ -135,7 +135,7 @@ impl fmt::Display for Offset {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Limit {
span: Option<Span>,
pub span: Option<Span>,
pub limit: IntegerLiteral,
}

Expand All @@ -161,7 +161,7 @@ impl fmt::Display for Limit {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Require {
span: Option<Span>,
pub span: Option<Span>,
pub variables: Vec<Variable>,
}

Expand Down
2 changes: 1 addition & 1 deletion rust/query/pipeline/stage/put.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ use crate::{

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Put {
span: Option<Span>,
pub span: Option<Span>,
pub statements: Vec<Statement>,
}

Expand Down
6 changes: 3 additions & 3 deletions rust/query/pipeline/stage/reduce.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ use crate::{

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Reduce {
span: Option<Span>,
pub span: Option<Span>,
pub reduce_assignments: Vec<ReduceAssign>,
pub groupby: Option<Vec<Variable>>,
}
Expand Down Expand Up @@ -105,7 +105,7 @@ impl fmt::Display for Reducer {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Count {
span: Option<Span>,
pub span: Option<Span>,
pub variable: Option<Variable>,
}

Expand Down Expand Up @@ -135,7 +135,7 @@ impl fmt::Display for Count {

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Stat {
span: Option<Span>,
pub span: Option<Span>,
pub reduce_operator: token::ReduceOperator,
pub variable: Variable,
}
Expand Down
2 changes: 1 addition & 1 deletion rust/query/pipeline/stage/update.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ use crate::{

#[derive(Debug, Clone, Eq, PartialEq)]
pub struct Update {
span: Option<Span>,
pub span: Option<Span>,
pub statements: Vec<Statement>,
}

Expand Down
2 changes: 1 addition & 1 deletion rust/query/schema/define.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ use crate::{

#[derive(Debug, Eq, PartialEq)]
pub struct Define {
span: Option<Span>,
pub span: Option<Span>,
pub definables: Vec<Definable>,
}

Expand Down
2 changes: 1 addition & 1 deletion rust/query/schema/redefine.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ use crate::{

#[derive(Debug, Eq, PartialEq)]
pub struct Redefine {
span: Option<Span>,
pub span: Option<Span>,
pub definables: Vec<Definable>,
}

Expand Down
2 changes: 1 addition & 1 deletion rust/query/schema/undefine.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ use crate::{

#[derive(Debug, Eq, PartialEq)]
pub struct Undefine {
span: Option<Span>,
pub span: Option<Span>,
pub undefinables: Vec<Undefinable>,
}

Expand Down
Loading

0 comments on commit ea9244f

Please sign in to comment.