-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Proof-of-concept size-based synchronization at top-level.
This aims to address a situation like this: type Chunks = unit { chunks: (Chunk &synchronize)[]; }; type Chunk = unit { content_size: bytes &until=b"\n" &convert=$$.to_uint(); content: bytes &size=self.content_size; }; If an error happens while parsing `content` (e.g., a gap in the input), the top-level `chunks` should be able to just move on the subsequent chunk because it's clear where that start (namely after `contents_size` bytes). This proof-of-concept implementation makes this example work, but isn't very pretty nor tested in detail; and other tests fail currently. Need to clean up and re-assess.
- Loading branch information
Showing
6 changed files
with
310 additions
and
102 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.