Skip to content
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

feat(histogram): expose histogram add functions #85

Merged
merged 1 commit into from
Oct 23, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion histogram/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "histogram"
version = "0.8.0"
version = "0.8.1"
edition = "2021"
authors = ["Brian Martin <brian@pelikan.io>"]
license = "MIT OR Apache-2.0"
Expand Down
4 changes: 2 additions & 2 deletions histogram/src/standard.rs
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ impl Histogram {
///
/// An error is returned if the two histograms have incompatible parameters
/// or if there is an overflow.
pub(crate) fn checked_add(&self, other: &Histogram) -> Result<Histogram, Error> {
pub fn checked_add(&self, other: &Histogram) -> Result<Histogram, Error> {
if self.config != other.config {
return Err(Error::IncompatibleParameters);
}
Expand All @@ -185,7 +185,7 @@ impl Histogram {
/// new histogram.
///
/// An error is returned if the two histograms have incompatible parameters.
pub(crate) fn wrapping_add(&self, other: &Histogram) -> Result<Histogram, Error> {
pub fn wrapping_add(&self, other: &Histogram) -> Result<Histogram, Error> {
if self.config != other.config {
return Err(Error::IncompatibleParameters);
}
Expand Down