Skip to content

Commit

Permalink
Merge pull request #147 from 01mf02/default-owned
Browse files Browse the repository at this point in the history
Correct `Default` implementation for `Owned` filters.
  • Loading branch information
01mf02 authored Jan 10, 2024
2 parents 2769ce6 + 4b074c7 commit 7416752
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion jaq-interpret/src/filter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,15 @@ use jaq_syn::filter::FoldType;
use jaq_syn::{MathOp, OrdOp};

/// Function from a value to a stream of value results.
#[derive(Debug, Default, Clone)]
#[derive(Debug, Clone)]
pub struct Owned(Id, Vec<Ast>);

impl Default for Owned {
fn default() -> Self {
Self(Id(0), Vec::from([Ast::Id]))
}
}

#[derive(Debug, Copy, Clone)]
pub struct Ref<'a>(Id, &'a [Ast]);

Expand Down

0 comments on commit 7416752

Please sign in to comment.