diff --git a/crates/json-pawarser/src/grammar.rs b/crates/json-pawarser/src/grammar.rs index 466f22c..3ececd8 100644 --- a/crates/json-pawarser/src/grammar.rs +++ b/crates/json-pawarser/src/grammar.rs @@ -4,8 +4,8 @@ use crate::{syntax_error::SyntaxError, syntax_kind::SyntaxKind}; use self::object::object; -pub(crate) type Parser<'src> = pawarser::Parser<'src, SyntaxKind, SyntaxError>; -pub(crate) type CompletedMarker = pawarser::CompletedMarker; +type Parser<'src, 'toks> = pawarser::Parser<'src, 'toks, SyntaxKind, SyntaxError>; +type CompletedMarker = pawarser::CompletedMarker; const BASIC_VALUE_TOKENS: EnumSet = enum_set!(SyntaxKind::BOOL | SyntaxKind::NULL | SyntaxKind::NUMBER | SyntaxKind::STRING); @@ -27,15 +27,12 @@ mod object { pub(super) fn object(p: &mut Parser) -> Option { let obj_start = p.start("object"); - if !p.eat(SyntaxKind::BRACE_OPEN) { + if !p.at(SyntaxKind::BRACE_OPEN) { obj_start.abandon(p); return None; } - member(p); - - p.eat(SyntaxKind::BRACE_CLOSE); - Some(obj_start.complete(p, SyntaxKind::OBJECT)) + todo!() } fn member(p: &mut Parser) -> Option { @@ -49,7 +46,7 @@ mod object { p.eat(SyntaxKind::STRING); member_name_start.complete(p, SyntaxKind::MEMBER_NAME); } else { - return todo!("handle other tokens: {:?}", p.current()); + return todo!("handle other tokens"); } if !p.eat(SyntaxKind::COLON) { diff --git a/crates/json-pawarser/src/lib.rs b/crates/json-pawarser/src/lib.rs index 05c529e..89160be 100644 --- a/crates/json-pawarser/src/lib.rs +++ b/crates/json-pawarser/src/lib.rs @@ -1,29 +1,3 @@ mod grammar; mod syntax_error; mod syntax_kind; - -#[cfg(test)] -mod test { - use pawarser::parser::ParserBuilder; - - use crate::{ - grammar::{value, Parser}, - syntax_kind::{lex, SyntaxKind}, - }; - - #[test] - fn test() { - const TEST_DATA: &str = r#"{"hello_world": "meow"}"#; - let toks = lex(TEST_DATA); - - let mut p: Parser = ParserBuilder::new(toks) - .add_meaningless(SyntaxKind::WHITESPACE) - .add_meaningless(SyntaxKind::NEWLINE) - .build(); - - value(&mut p); - - let out = p.finish(); - assert_eq!("", format!("{:#?}", out)) - } -} diff --git a/crates/json-pawarser/src/syntax_error.rs b/crates/json-pawarser/src/syntax_error.rs index 45bb5bd..6ff9067 100644 --- a/crates/json-pawarser/src/syntax_error.rs +++ b/crates/json-pawarser/src/syntax_error.rs @@ -1,6 +1,6 @@ use crate::syntax_kind::SyntaxKind; -#[derive(Debug, Clone, PartialEq, Eq)] +#[derive(Clone)] pub enum SyntaxError { DisallowedKeyType(SyntaxKind), MemberMissingValue, diff --git a/crates/json-pawarser/src/syntax_kind.rs b/crates/json-pawarser/src/syntax_kind.rs index dfaab13..9d3dc2c 100644 --- a/crates/json-pawarser/src/syntax_kind.rs +++ b/crates/json-pawarser/src/syntax_kind.rs @@ -16,6 +16,14 @@ pub fn lex(src: &str) -> Vec<(SyntaxKind, &str)> { #[enumset(no_super_impls)] #[allow(non_camel_case_types)] pub enum SyntaxKind { + // Error SyntaxKinds + LEX_ERR, + PARSE_ERR, + + // Meta SyntaxKinds + TOMBSTONE, + EOF, + OBJECT, MEMBER, MEMBER_NAME, @@ -53,13 +61,6 @@ pub enum SyntaxKind { WHITESPACE, #[token("\n")] NEWLINE, - - // Error SyntaxKinds - LEX_ERR, - PARSE_ERR, - - // Meta SyntaxKinds - EOF, } impl pawarser::parser::SyntaxElement for SyntaxKind { @@ -74,16 +75,6 @@ impl From for rowan::SyntaxKind { } } -impl From for SyntaxKind { - fn from(raw: rowan::SyntaxKind) -> Self { - assert!(raw.0 <= SyntaxKind::EOF as u16); - #[allow(unsafe_code, reason = "The transmute is necessary here")] - unsafe { - std::mem::transmute::(raw.0) - } - } -} - #[cfg(test)] mod tests { use crate::syntax_kind::{lex, SyntaxKind}; diff --git a/crates/pawarser/src/parser.rs b/crates/pawarser/src/parser.rs index 2a666bf..09b1bf4 100644 --- a/crates/pawarser/src/parser.rs +++ b/crates/pawarser/src/parser.rs @@ -1,29 +1,19 @@ -use std::{cell::Cell, fmt, marker::PhantomData, mem}; +use std::cell::Cell; use enumset::{EnumSet, EnumSetType}; -use rowan::{GreenNode, GreenNodeBuilder}; - -use crate::parser::event::NodeKind; use self::{event::Event, input::Input, marker::Marker}; -pub use {error::SyntaxError, output::ParserOutput}; +pub use error::SyntaxError; pub mod error; mod event; mod input; pub mod marker; -pub mod output; /// this is used to define some required SyntaxKinds like an EOF token or an error token pub trait SyntaxElement where - Self: EnumSetType - + Into - + From - + fmt::Debug - + Clone - + PartialEq - + Eq, + Self: EnumSetType + Into + Clone, { /// EOF value. This will be used by the rest of the parser library to represent an EOF. const EOF: Self; @@ -31,8 +21,8 @@ where const ERROR: Self; } -pub struct Parser<'src, SyntaxKind: SyntaxElement, SyntaxErr: SyntaxError> { - input: Input<'src, SyntaxKind>, +pub struct Parser<'src, 'toks, SyntaxKind: SyntaxElement, SyntaxErr: SyntaxError> { + input: Input<'src, 'toks, SyntaxKind>, pos: usize, events: Vec>, step_limit: u32, @@ -40,7 +30,7 @@ pub struct Parser<'src, SyntaxKind: SyntaxElement, SyntaxErr: SyntaxError> { } impl<'src, 'toks, SyntaxKind: SyntaxElement, SyntaxErr: SyntaxError> - Parser<'src, SyntaxKind, SyntaxErr> + Parser<'src, 'toks, SyntaxKind, SyntaxErr> { /// eat all meaningless tokens at the end of the file. pub fn eat_succeeding_meaningless(&mut self) { @@ -103,107 +93,21 @@ impl<'src, 'toks, SyntaxKind: SyntaxElement, SyntaxErr: SyntaxError> assert!(steps <= self.step_limit, "the parser seems stuck."); self.steps.set(steps + 1); } - - pub fn finish(self) -> ParserOutput { - let Self { - input, - pos, - mut events, - step_limit, - steps, - } = self; - let (mut raw_toks, meaningless_tokens) = input.dissolve(); - let mut builder = GreenNodeBuilder::new(); - // TODO: document what the hell a forward parent is - let mut fw_parents = Vec::new(); - let mut errors: Vec = Vec::new(); - raw_toks.reverse(); - - for i in 0..events.len() { - match mem::replace(&mut events[i], Event::tombstone()) { - Event::Start { - kind, - forward_parent, - } => { - if kind == NodeKind::Tombstone && forward_parent.is_none() { - continue; - } - - // resolving forward parents - // temporarily jump around with the parser index and replace them with tombstones - fw_parents.push(kind); - let mut idx = i; - let mut fp = forward_parent; - while let Some(fwd) = fp { - idx += fwd as usize; - fp = match mem::replace(&mut events[idx], Event::tombstone()) { - Event::Start { - kind, - forward_parent, - } => { - fw_parents.push(kind); - forward_parent - } - _ => unreachable!(), - } - } - - // clear semantically meaningless tokens before the new tree node for aesthetic reasons - while raw_toks - .last() - .is_some_and(|v| meaningless_tokens.contains(v.0)) - { - // update first next Eat event - match events.iter_mut().find(|ev| matches!(ev, Event::Eat { .. })) { - Some(Event::Eat { count }) => *count -= 1, - _ => unreachable!(), - } - - // put whitespace into lst - let (tok, text) = raw_toks.pop().unwrap(); - builder.token(tok.into(), text); - } - - // insert forward parents into the tree in correct order - for kind in fw_parents.drain(..).rev() { - match kind { - NodeKind::Syntax(kind) => builder.start_node(kind.into()), - NodeKind::Error(err) => { - errors.push(err); - builder.start_node(SyntaxKind::ERROR.into()) - } - _ => {} - } - } - } - Event::Finish => builder.finish_node(), - Event::Eat { count } => (0..count).for_each(|_| { - let (tok, text) = raw_toks.pop().unwrap(); - builder.token(tok.into(), text); - }), - } - } - - ParserOutput { - green_node: builder.finish(), - errors, - _syntax_kind: PhantomData::, - } - } } pub struct ParserBuilder< 'src, + 'toks, SyntaxKind: SyntaxElement, // SyntaxErr: SyntaxError, > { - raw_toks: Vec<(SyntaxKind, &'src str)>, + raw_toks: &'toks Vec<(SyntaxKind, &'src str)>, meaningless_token_kinds: EnumSet, step_limit: u32, } -impl<'src, SyntaxKind: SyntaxElement> ParserBuilder<'src, SyntaxKind> { - pub fn new(raw_toks: Vec<(SyntaxKind, &'src str)>) -> Self { +impl<'src, 'toks, SyntaxKind: SyntaxElement> ParserBuilder<'src, 'toks, SyntaxKind> { + pub fn new(raw_toks: &'toks Vec<(SyntaxKind, &'src str)>) -> Self { Self { raw_toks, meaningless_token_kinds: EnumSet::new(), @@ -229,7 +133,7 @@ impl<'src, SyntaxKind: SyntaxElement> ParserBuilder<'src, SyntaxKind> { self } - pub fn build(self) -> Parser<'src, SyntaxKind, SyntaxErr> { + pub fn build(self) -> Parser<'src, 'toks, SyntaxKind, SyntaxErr> { let Self { raw_toks, meaningless_token_kinds, diff --git a/crates/pawarser/src/parser/error.rs b/crates/pawarser/src/parser/error.rs index 9c9d893..ba52ff0 100644 --- a/crates/pawarser/src/parser/error.rs +++ b/crates/pawarser/src/parser/error.rs @@ -1,9 +1,7 @@ -use std::fmt; - /// A marker trait... for now! // TODO: constrain that conversion to `NodeKind::Error` is enforced to be possible pub trait SyntaxError where - Self: fmt::Debug + Clone + PartialEq + Eq, + Self: Clone, { } diff --git a/crates/pawarser/src/parser/event.rs b/crates/pawarser/src/parser/event.rs index 1b71d8e..3cd0ef5 100644 --- a/crates/pawarser/src/parser/event.rs +++ b/crates/pawarser/src/parser/event.rs @@ -22,7 +22,7 @@ impl Event { Tombstone, Syntax(SyntaxKind), diff --git a/crates/pawarser/src/parser/input.rs b/crates/pawarser/src/parser/input.rs index a20d73d..ec2a243 100644 --- a/crates/pawarser/src/parser/input.rs +++ b/crates/pawarser/src/parser/input.rs @@ -2,17 +2,17 @@ use enumset::{EnumSet, EnumSetType}; use super::SyntaxElement; -pub struct Input<'src, SyntaxKind: SyntaxElement> { - raw: Vec<(SyntaxKind, &'src str)>, +pub struct Input<'src, 'toks, SyntaxKind: SyntaxElement> { + raw: &'toks Vec<(SyntaxKind, &'src str)>, // enumset of meaningless tokens semantically_meaningless: EnumSet, // indices of non-meaningless tokens meaningful_toks: Vec, } -impl<'src, SyntaxKind: SyntaxElement> Input<'src, SyntaxKind> { +impl<'src, 'toks, SyntaxKind: SyntaxElement> Input<'src, 'toks, SyntaxKind> { pub fn new( - raw_toks: Vec<(SyntaxKind, &'src str)>, + raw_toks: &'toks Vec<(SyntaxKind, &'src str)>, meaningless: Option>, ) -> Self { let mut meaningful_toks = Vec::new(); @@ -55,13 +55,4 @@ impl<'src, SyntaxKind: SyntaxElement> Input<'src, SyntaxKind> { pub fn meaningless_tail_len(&self) -> usize { self.raw.len() - (self.meaningful_toks.last().unwrap() + 1) } - - pub fn dissolve(self) -> (Vec<(SyntaxKind, &'src str)>, EnumSet) { - let Self { - raw, - semantically_meaningless, - .. - } = self; - (raw, semantically_meaningless) - } } diff --git a/crates/pawarser/src/parser/marker.rs b/crates/pawarser/src/parser/marker.rs index d03e358..2d3fc5a 100644 --- a/crates/pawarser/src/parser/marker.rs +++ b/crates/pawarser/src/parser/marker.rs @@ -69,17 +69,6 @@ pub struct CompletedMarker { impl CompletedMarker { pub fn precede(self, p: &mut Parser, name: &str) -> Marker { - let new_pos = p.start(name); - - match &mut p.events[self.pos] { - Event::Start { forward_parent, .. } => { - // point forward parent of the node this marker completed to the new node - // will later be used to make the new node a parent of the current node. - *forward_parent = Some(new_pos.pos - self.pos) - } - _ => unreachable!(), - } - - new_pos + todo!() } } diff --git a/crates/pawarser/src/parser/output.rs b/crates/pawarser/src/parser/output.rs deleted file mode 100644 index bea13e8..0000000 --- a/crates/pawarser/src/parser/output.rs +++ /dev/null @@ -1,67 +0,0 @@ -use std::{fmt, marker::PhantomData}; - -use rowan::{GreenNode, GreenNodeData, GreenTokenData, NodeOrToken}; - -use crate::{SyntaxElement, SyntaxError}; - -pub struct ParserOutput { - pub green_node: GreenNode, - pub errors: Vec, - pub(super) _syntax_kind: PhantomData, -} - -impl std::fmt::Debug - for ParserOutput -{ - fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { - let mut errs: Vec<&SyntaxErr> = self.errors.iter().collect(); - errs.reverse(); - debug_print_output::( - NodeOrToken::Node(&self.green_node), - f, - 0, - &mut errs, - ) - } -} - -fn debug_print_output( - node: NodeOrToken<&GreenNodeData, &GreenTokenData>, - f: &mut std::fmt::Formatter<'_>, - lvl: i32, - errs: &mut Vec<&SyntaxErr>, -) -> std::fmt::Result { - for _ in 0..lvl { - f.write_str(" ")?; - } - - match node { - NodeOrToken::Node(n) => { - let kind: SyntaxKind = node.kind().into(); - if kind != SyntaxKind::ERROR { - writeln!(f, "{:?} {{", kind)?; - } else { - let err = errs - .pop() - .expect("all error syntax nodes should correspond to an error"); - - writeln!(f, "{:?}: {err:?} {{", kind)?; - } - for c in n.children() { - debug_print_output::(c, f, lvl + 1, errs)?; - } - for _ in 0..lvl { - f.write_str(" ")?; - } - f.write_str("}\n") - } - NodeOrToken::Token(t) => { - writeln!( - f, - "{:?} {:?};", - Into::::into(t.kind()), - t.text() - ) - } - } -} diff --git a/flake.lock b/flake.lock index 0d61b34..9719001 100644 --- a/flake.lock +++ b/flake.lock @@ -3,54 +3,12 @@ "cachix": { "inputs": { "devenv": "devenv_2", - "flake-compat": [ - "devenv", - "flake-compat" - ], - "git-hooks": [ - "devenv", - "pre-commit-hooks" - ], + "flake-compat": "flake-compat_2", "nixpkgs": [ "devenv", "nixpkgs" - ] - }, - "locked": { - "lastModified": 1726520618, - "narHash": "sha256-jOsaBmJ/EtX5t/vbylCdS7pWYcKGmWOKg4QKUzKr6dA=", - "owner": "cachix", - "repo": "cachix", - "rev": "695525f9086542dfb09fde0871dbf4174abbf634", - "type": "github" - }, - "original": { - "owner": "cachix", - "repo": "cachix", - "type": "github" - } - }, - "cachix_2": { - "inputs": { - "devenv": "devenv_3", - "flake-compat": [ - "devenv", - "cachix", - "devenv", - "flake-compat" ], - "nixpkgs": [ - "devenv", - "cachix", - "devenv", - "nixpkgs" - ], - "pre-commit-hooks": [ - "devenv", - "cachix", - "devenv", - "pre-commit-hooks" - ] + "pre-commit-hooks": "pre-commit-hooks" }, "locked": { "lastModified": 1712055811, @@ -69,17 +27,17 @@ "devenv": { "inputs": { "cachix": "cachix", - "flake-compat": "flake-compat_2", - "nix": "nix_3", - "nixpkgs": "nixpkgs_3", + "flake-compat": "flake-compat_4", + "nix": "nix_2", + "nixpkgs": "nixpkgs_2", "pre-commit-hooks": "pre-commit-hooks_2" }, "locked": { - "lastModified": 1729445229, - "narHash": "sha256-3vhSEs2ufSvv2Oct8G9CWEPFI57c4NAZ2wR2accHELM=", + "lastModified": 1712925466, + "narHash": "sha256-MJ6VxGNu/ftbn8SErJjBz80FUNXkZfcObHg/JP7wwAc=", "owner": "cachix", "repo": "devenv", - "rev": "006016cf4191c34c17cfdb6669e0690e24302ac0", + "rev": "1af93652caf48bfeef6ba7d1cf59fc66e506e5c2", "type": "github" }, "original": { @@ -90,53 +48,15 @@ }, "devenv_2": { "inputs": { - "cachix": "cachix_2", "flake-compat": [ "devenv", "cachix", "flake-compat" ], - "nix": "nix_2", - "nixpkgs": [ - "devenv", - "cachix", - "nixpkgs" - ], - "pre-commit-hooks": [ - "devenv", - "cachix", - "git-hooks" - ] - }, - "locked": { - "lastModified": 1723156315, - "narHash": "sha256-0JrfahRMJ37Rf1i0iOOn+8Z4CLvbcGNwa2ChOAVrp/8=", - "owner": "cachix", - "repo": "devenv", - "rev": "ff5eb4f2accbcda963af67f1a1159e3f6c7f5f91", - "type": "github" - }, - "original": { - "owner": "cachix", - "repo": "devenv", - "type": "github" - } - }, - "devenv_3": { - "inputs": { - "flake-compat": [ - "devenv", - "cachix", - "devenv", - "cachix", - "flake-compat" - ], "nix": "nix", "nixpkgs": "nixpkgs", "poetry2nix": "poetry2nix", "pre-commit-hooks": [ - "devenv", - "cachix", "devenv", "cachix", "pre-commit-hooks" @@ -159,15 +79,15 @@ }, "fenix": { "inputs": { - "nixpkgs": "nixpkgs_4", + "nixpkgs": "nixpkgs_3", "rust-analyzer-src": "rust-analyzer-src" }, "locked": { - "lastModified": 1729492502, - "narHash": "sha256-d6L4bBlUWr4sHC+eRXo+4acFPEFXKmqHpM/BfQ5gQQw=", + "lastModified": 1712903033, + "narHash": "sha256-KcvsEm0h1mIwBHFAzWFBjGihnbf2fxpAaXOdVbUfAI4=", "owner": "nix-community", "repo": "fenix", - "rev": "4002a1ec3486b855f341d2b864ba06b61e73af28", + "rev": "c739f83545e625227f4d0af7fe2a71e69931fa4c", "type": "github" }, "original": { @@ -208,25 +128,51 @@ "type": "github" } }, - "flake-parts": { - "inputs": { - "nixpkgs-lib": [ - "devenv", - "nix", - "nixpkgs" - ] - }, + "flake-compat_3": { + "flake": false, "locked": { - "lastModified": 1712014858, - "narHash": "sha256-sB4SWl2lX95bExY2gMFG5HIzvva5AVMJd4Igm+GpZNw=", - "owner": "hercules-ci", - "repo": "flake-parts", - "rev": "9126214d0a59633752a136528f5f3b9aa8565b7d", + "lastModified": 1696426674, + "narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=", + "owner": "edolstra", + "repo": "flake-compat", + "rev": "0f9255e01c2351cc7d116c072cb317785dd33b33", "type": "github" }, "original": { - "owner": "hercules-ci", - "repo": "flake-parts", + "owner": "edolstra", + "repo": "flake-compat", + "type": "github" + } + }, + "flake-compat_4": { + "flake": false, + "locked": { + "lastModified": 1696426674, + "narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=", + "owner": "edolstra", + "repo": "flake-compat", + "rev": "0f9255e01c2351cc7d116c072cb317785dd33b33", + "type": "github" + }, + "original": { + "owner": "edolstra", + "repo": "flake-compat", + "type": "github" + } + }, + "flake-compat_5": { + "flake": false, + "locked": { + "lastModified": 1673956053, + "narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=", + "owner": "edolstra", + "repo": "flake-compat", + "rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9", + "type": "github" + }, + "original": { + "owner": "edolstra", + "repo": "flake-compat", "type": "github" } }, @@ -249,12 +195,33 @@ } }, "flake-utils_2": { + "inputs": { + "systems": "systems_2" + }, "locked": { - "lastModified": 1667395993, - "narHash": "sha256-nuEHfE/LcWyuSWnS8t12N1wc105Qtau+/OdUAjtQ0rA=", + "lastModified": 1701680307, + "narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=", "owner": "numtide", "repo": "flake-utils", - "rev": "5aed5285a952e0b949eb3ba02c12fa4fcfef535f", + "rev": "4022d587cbbfd70fe950c1e2083a02621806a725", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, + "flake-utils_3": { + "inputs": { + "systems": "systems_3" + }, + "locked": { + "lastModified": 1710146030, + "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", "type": "github" }, "original": { @@ -264,6 +231,29 @@ } }, "gitignore": { + "inputs": { + "nixpkgs": [ + "devenv", + "cachix", + "pre-commit-hooks", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1703887061, + "narHash": "sha256-gGPa9qWNc6eCXT/+Z5/zMkyYOuRZqeFZBDbopNZQkuY=", + "owner": "hercules-ci", + "repo": "gitignore.nix", + "rev": "43e1aa1308018f37118e34d3a9cb4f5e75dc11d5", + "type": "github" + }, + "original": { + "owner": "hercules-ci", + "repo": "gitignore.nix", + "type": "github" + } + }, + "gitignore_2": { "inputs": { "nixpkgs": [ "devenv", @@ -285,28 +275,10 @@ "type": "github" } }, - "libgit2": { - "flake": false, - "locked": { - "lastModified": 1697646580, - "narHash": "sha256-oX4Z3S9WtJlwvj0uH9HlYcWv+x1hqp8mhXl7HsLu2f0=", - "owner": "libgit2", - "repo": "libgit2", - "rev": "45fd9ed7ae1a9b74b957ef4f337bc3c8b3df01b5", - "type": "github" - }, - "original": { - "owner": "libgit2", - "repo": "libgit2", - "type": "github" - } - }, "nix": { "inputs": { "flake-compat": "flake-compat", "nixpkgs": [ - "devenv", - "cachix", "devenv", "cachix", "devenv", @@ -315,11 +287,11 @@ "nixpkgs-regression": "nixpkgs-regression" }, "locked": { - "lastModified": 1712911606, - "narHash": "sha256-BGvBhepCufsjcUkXnEEXhEVjwdJAwPglCC2+bInc794=", + "lastModified": 1708577783, + "narHash": "sha256-92xq7eXlxIT5zFNccLpjiP7sdQqQI30Gyui2p/PfKZM=", "owner": "domenkozar", "repo": "nix", - "rev": "b24a9318ea3f3600c1e24b4a00691ee912d4de12", + "rev": "ecd0af0c1f56de32cbad14daa1d82a132bf298f8", "type": "github" }, "original": { @@ -332,8 +304,6 @@ "nix-github-actions": { "inputs": { "nixpkgs": [ - "devenv", - "cachix", "devenv", "cachix", "devenv", @@ -357,15 +327,8 @@ }, "nix_2": { "inputs": { - "flake-compat": [ - "devenv", - "cachix", - "devenv", - "flake-compat" - ], + "flake-compat": "flake-compat_5", "nixpkgs": [ - "devenv", - "cachix", "devenv", "nixpkgs" ], @@ -386,34 +349,6 @@ "type": "github" } }, - "nix_3": { - "inputs": { - "flake-compat": [ - "devenv", - "flake-compat" - ], - "flake-parts": "flake-parts", - "libgit2": "libgit2", - "nixpkgs": "nixpkgs_2", - "nixpkgs-23-11": "nixpkgs-23-11", - "nixpkgs-regression": "nixpkgs-regression_3", - "pre-commit-hooks": "pre-commit-hooks" - }, - "locked": { - "lastModified": 1727438425, - "narHash": "sha256-X8ES7I1cfNhR9oKp06F6ir4Np70WGZU5sfCOuNBEwMg=", - "owner": "domenkozar", - "repo": "nix", - "rev": "f6c5ae4c1b2e411e6b1e6a8181cc84363d6a7546", - "type": "github" - }, - "original": { - "owner": "domenkozar", - "ref": "devenv-2.24", - "repo": "nix", - "type": "github" - } - }, "nixpkgs": { "locked": { "lastModified": 1692808169, @@ -430,22 +365,6 @@ "type": "github" } }, - "nixpkgs-23-11": { - "locked": { - "lastModified": 1717159533, - "narHash": "sha256-oamiKNfr2MS6yH64rUn99mIZjc45nGJlj9eGth/3Xuw=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "a62e6edd6d5e1fa0329b8653c801147986f8d446", - "type": "github" - }, - "original": { - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "a62e6edd6d5e1fa0329b8653c801147986f8d446", - "type": "github" - } - }, "nixpkgs-regression": { "locked": { "lastModified": 1643052045, @@ -478,61 +397,45 @@ "type": "github" } }, - "nixpkgs-regression_3": { + "nixpkgs-stable": { "locked": { - "lastModified": 1643052045, - "narHash": "sha256-uGJ0VXIhWKGXxkeNnq4TvV3CIOkUJ3PAoLZ3HMzNVMw=", + "lastModified": 1704874635, + "narHash": "sha256-YWuCrtsty5vVZvu+7BchAxmcYzTMfolSPP5io8+WYCg=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "215d4d0fd80ca5163643b03a33fde804a29cc1e2", + "rev": "3dc440faeee9e889fe2d1b4d25ad0f430d449356", "type": "github" }, "original": { "owner": "NixOS", + "ref": "nixos-23.11", "repo": "nixpkgs", - "rev": "215d4d0fd80ca5163643b03a33fde804a29cc1e2", "type": "github" } }, - "nixpkgs-stable": { + "nixpkgs-stable_2": { "locked": { - "lastModified": 1720386169, - "narHash": "sha256-NGKVY4PjzwAa4upkGtAMz1npHGoRzWotlSnVlqI40mo=", + "lastModified": 1710695816, + "narHash": "sha256-3Eh7fhEID17pv9ZxrPwCLfqXnYP006RKzSs0JptsN84=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "194846768975b7ad2c4988bdb82572c00222c0d7", + "rev": "614b4613980a522ba49f0d194531beddbb7220d3", "type": "github" }, "original": { "owner": "NixOS", - "ref": "nixos-24.05", + "ref": "nixos-23.11", "repo": "nixpkgs", "type": "github" } }, "nixpkgs_2": { "locked": { - "lastModified": 1717432640, - "narHash": "sha256-+f9c4/ZX5MWDOuB1rKoWj+lBNm0z0rs4CK47HBLxy1o=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "88269ab3044128b7c2f4c7d68448b2fb50456870", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "release-24.05", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs_3": { - "locked": { - "lastModified": 1716977621, - "narHash": "sha256-Q1UQzYcMJH4RscmpTkjlgqQDX5yi1tZL0O345Ri6vXQ=", + "lastModified": 1710796454, + "narHash": "sha256-lQlICw60RhH8sHTDD/tJiiJrlAfNn8FDI9c+7G2F0SE=", "owner": "cachix", "repo": "devenv-nixpkgs", - "rev": "4267e705586473d3e5c8d50299e71503f16a6fb6", + "rev": "06fb0f1c643aee3ae6838dda3b37ef0abc3c763b", "type": "github" }, "original": { @@ -542,13 +445,13 @@ "type": "github" } }, - "nixpkgs_4": { + "nixpkgs_3": { "locked": { - "lastModified": 1729256560, - "narHash": "sha256-/uilDXvCIEs3C9l73JTACm4quuHUsIHcns1c+cHUJwA=", + "lastModified": 1712791164, + "narHash": "sha256-3sbWO1mbpWsLepZGbWaMovSO7ndZeFqDSdX0hZ9nVyw=", "owner": "nixos", "repo": "nixpkgs", - "rev": "4c2fcb090b1f3e5b47eaa7bd33913b574a11e0a0", + "rev": "1042fd8b148a9105f3c0aca3a6177fd1d9360ba5", "type": "github" }, "original": { @@ -558,13 +461,13 @@ "type": "github" } }, - "nixpkgs_5": { + "nixpkgs_4": { "locked": { - "lastModified": 1729256560, - "narHash": "sha256-/uilDXvCIEs3C9l73JTACm4quuHUsIHcns1c+cHUJwA=", + "lastModified": 1712791164, + "narHash": "sha256-3sbWO1mbpWsLepZGbWaMovSO7ndZeFqDSdX0hZ9nVyw=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "4c2fcb090b1f3e5b47eaa7bd33913b574a11e0a0", + "rev": "1042fd8b148a9105f3c0aca3a6177fd1d9360ba5", "type": "github" }, "original": { @@ -579,8 +482,6 @@ "flake-utils": "flake-utils", "nix-github-actions": "nix-github-actions", "nixpkgs": [ - "devenv", - "cachix", "devenv", "cachix", "devenv", @@ -603,25 +504,43 @@ }, "pre-commit-hooks": { "inputs": { - "flake-compat": [ - "devenv", - "nix" - ], + "flake-compat": "flake-compat_3", "flake-utils": "flake-utils_2", - "gitignore": [ - "devenv", - "nix" - ], + "gitignore": "gitignore", "nixpkgs": [ "devenv", - "nix", + "cachix", "nixpkgs" ], - "nixpkgs-stable": [ + "nixpkgs-stable": "nixpkgs-stable" + }, + "locked": { + "lastModified": 1708018599, + "narHash": "sha256-M+Ng6+SePmA8g06CmUZWi1AjG2tFBX9WCXElBHEKnyM=", + "owner": "cachix", + "repo": "pre-commit-hooks.nix", + "rev": "5df5a70ad7575f6601d91f0efec95dd9bc619431", + "type": "github" + }, + "original": { + "owner": "cachix", + "repo": "pre-commit-hooks.nix", + "type": "github" + } + }, + "pre-commit-hooks_2": { + "inputs": { + "flake-compat": [ + "devenv", + "flake-compat" + ], + "flake-utils": "flake-utils_3", + "gitignore": "gitignore_2", + "nixpkgs": [ "devenv", - "nix", "nixpkgs" - ] + ], + "nixpkgs-stable": "nixpkgs-stable_2" }, "locked": { "lastModified": 1712897695, @@ -637,49 +556,22 @@ "type": "github" } }, - "pre-commit-hooks_2": { - "inputs": { - "flake-compat": [ - "devenv", - "flake-compat" - ], - "gitignore": "gitignore", - "nixpkgs": [ - "devenv", - "nixpkgs" - ], - "nixpkgs-stable": "nixpkgs-stable" - }, - "locked": { - "lastModified": 1726745158, - "narHash": "sha256-D5AegvGoEjt4rkKedmxlSEmC+nNLMBPWFxvmYnVLhjk=", - "owner": "cachix", - "repo": "pre-commit-hooks.nix", - "rev": "4e743a6920eab45e8ba0fbe49dc459f1423a4b74", - "type": "github" - }, - "original": { - "owner": "cachix", - "repo": "pre-commit-hooks.nix", - "type": "github" - } - }, "root": { "inputs": { "devenv": "devenv", "fenix": "fenix", - "nixpkgs": "nixpkgs_5", - "systems": "systems_2" + "nixpkgs": "nixpkgs_4", + "systems": "systems_4" } }, "rust-analyzer-src": { "flake": false, "locked": { - "lastModified": 1729454508, - "narHash": "sha256-1W5B/CnLgdC03iIFG0wtawO1+dGDWDpc84PeOHo2ecU=", + "lastModified": 1712818880, + "narHash": "sha256-VDxsvgj/bNypHq48tQWtc3VRbWvzlFjzKf9ZZIVO10Y=", "owner": "rust-lang", "repo": "rust-analyzer", - "rev": "9323b5385863739d1c113f02e4cf3f2777c09977", + "rev": "657b33b0cb9bd49085202e91ad5b4676532c9140", "type": "github" }, "original": { @@ -718,6 +610,36 @@ "repo": "default", "type": "github" } + }, + "systems_3": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + }, + "systems_4": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } } }, "root": "root",