Skip to content

Commit

Permalink
Adding scopes and edges is actually a mutable operation
Browse files Browse the repository at this point in the history
  • Loading branch information
AZWN committed Nov 16, 2023
1 parent 294edde commit b804b15
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scopegraphs/src/scopegraphs/traits.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ pub trait ScopeGraph {
type Label;
type Data;

fn add_scope(&self, data: Self::Data) -> &Self::Scope;
fn add_scope(&mut self, data: Self::Data) -> &Self::Scope;

fn add_edge(&self, src: &Self::Scope, lbl: &Self::Label, dst: &Self::Scope);
fn add_edge(&mut self, src: &Self::Scope, lbl: &Self::Label, dst: &Self::Scope);

fn get_data(&self, scope: &Self::Scope) -> &Self::Data;

Expand Down

0 comments on commit b804b15

Please sign in to comment.