-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Switch Sequence and Tag indices to unsigned (#438)
* Switch to Sequence indices to unsigned (fixes signed integer overflow UB) * Make tag index unsigned Make the normal tag index unsigned (std::size_t), to match the new sequence index type. * Remove Sequence::index_type * Remove Tag::index_type and replace gr::RelativeIndexTag by simple std::pair. There's three cases where we need relative indices though: - Port::tags() provides the tags with indices relative to stream position. - DataSet::timing_events are relative to the first sample in the set, and can be negative (e.g. for DataSink's snapshot acquisition mode, the trigger is in the past. - DataSink callback and pollers use tags relative to the current data chunk. For these, use RelativeIndexTag, which have a signed index type. Signed-off-by: Frank Osterfeld <[email protected]>
- Loading branch information
1 parent
af92697
commit 3273d08
Showing
27 changed files
with
264 additions
and
286 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
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.