-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Message Codec #1692
Merged
Merged
Message Codec #1692
Changes from 20 commits
Commits
Show all changes
33 commits
Select commit
Hold shift + click to select a range
ff69266
Message cleanup
gatesn d1cd362
Move expr
gatesn 54ddfd8
Clean up
gatesn b368ec0
Clean up
gatesn 34edbf5
Clean up
gatesn 4d02906
message reader
gatesn cc65637
Message codec
gatesn 21ce1b9
Message codec
gatesn 831d41e
Message codec
gatesn 0010f00
Message codec
gatesn 8c55100
Message codec
gatesn 29a78a1
Message codec
gatesn bbda9e6
Message Codecs
gatesn 5a7c8ab
Message Codecs
gatesn 75fd1e0
Message Codecs
gatesn 0c333b9
merge
gatesn 92a7d6e
merge
gatesn b474b4b
Merge
gatesn 7e1c80f
Merge
gatesn 92062d8
Fix docs
gatesn 87ba232
Assert alignment
gatesn f4d6fdf
Merge branch 'develop' into ngates/message-reader
gatesn 1b285e6
Address comments
gatesn e532fa6
Address comments
gatesn ca4e632
Address comments
gatesn d7c38be
Address comments
gatesn fe46f61
Address comments
gatesn 80c6fcc
Address comments
gatesn 20f8b18
Address comments
gatesn 78d9f0d
Fix decoder
gatesn 94ae305
Fix decoder
gatesn 5b21ae7
Remove unpin bounds
gatesn 2040b0d
Add PrimInt bound to VarBinOffset
gatesn File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
use std::fmt::{Display, Formatter}; | ||
use std::ops::Range; | ||
|
||
use vortex_error::VortexUnwrap; | ||
|
||
#[derive(Copy, Clone, Debug)] | ||
pub struct ByteRange { | ||
pub begin: u64, | ||
pub end: u64, | ||
} | ||
|
||
impl Display for ByteRange { | ||
fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result { | ||
write!(f, "[{}, {})", self.begin, self.end) | ||
} | ||
} | ||
|
||
impl ByteRange { | ||
pub fn new(begin: u64, end: u64) -> Self { | ||
assert!(begin < end, "Buffer begin must be before its end"); | ||
Self { begin, end } | ||
} | ||
|
||
pub fn len(&self) -> u64 { | ||
self.end - self.begin | ||
} | ||
|
||
pub fn is_empty(&self) -> bool { | ||
self.begin == self.end | ||
} | ||
|
||
pub fn as_range(&self) -> Range<usize> { | ||
Range { | ||
// TODO(ngates): this cast is unsafe and can panic | ||
start: self.begin.try_into().vortex_unwrap(), | ||
end: self.end.try_into().vortex_unwrap(), | ||
} | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
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.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This messy test code will be refactored when I get around to the layouts