Skip to content

Commit

Permalink
Remove reexport of bits::* in crate root (#1485)
Browse files Browse the repository at this point in the history
* Remove reexport of bits::* in crate root

This reexport seems to be a remnant from the days of macro parsers,
which no longer exist.

It has caused confusion on several occasions. nom::complete::tag, for
example, refers to nom::bits::complete::tag, while users actually want
nom::bytes::complete::tag in the vast majority of cases.

* Update CHANGELOG.md for PR#1485
  • Loading branch information
Xiretza committed May 5, 2024
1 parent d356bbe commit 5c4fe61
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@

### Thanks

### Removed

- `nom::bits::*` is no longer re-exported at the crate root. This export caused frequent confusion, since e.g. `nom::complete::tag` referred to `nom::bits::complete::tag` instead of the much more commonly used `nom::bytes::complete::tag`. To migrate, change any imports of `nom::{complete::*, streaming::*, bits, bytes}` to `nom::bits::[...]`.

### Changed

## 7.1.2 - 2023-01-01
Expand Down
1 change: 0 additions & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,6 @@ pub mod lib {
}
}

pub use self::bits::*;
pub use self::internal::*;
pub use self::traits::*;

Expand Down

0 comments on commit 5c4fe61

Please sign in to comment.