Skip to content

Rename bstr module/feature to byte_str - #160912

Merged
rust-bors[bot] merged 1 commit into
rust-lang:mainfrom
clarfonthey:byte-str-module
Oct 18, 2026
Merged

rust-bors[bot] merged 1 commit into
rust-lang:mainfrom
clarfonthey:byte-str-module

Conversation

@clarfonthey

@clarfonthey clarfonthey commented Aug 11, 2026 •

Copy link
Copy Markdown
Contributor

View all comments

This also renames the various features to use byte_str instead of bstr.

This was discussed by libs and agreed on as being more consistent with the types contained in the module. However, we remain open to renaming back before stabilization if warranted.

For now, byte_str::ByteStr makes the most sense.

(To be clear, bstr::ByteStr and byte_str::BStr are both undesired.)

@rustbot rustbot added O-apple Operating system: Apple / Darwin (macOS, iOS, tvOS, visionOS, watchOS) O-unix Operating system: Unix-like O-windows Operating system: Windows labels Aug 11, 2026
@rustbot

rustbot commented Aug 11, 2026

Copy link
Copy Markdown
Collaborator

r? @Mark-Simulacrum

rustbot has assigned @Mark-Simulacrum.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

Why was this reviewer chosen?

The reviewer was selected based on:

  • Owners of files modified in this PR: libs
  • libs expanded to 12 candidates
  • Random selection from JohnTitor, Mark-Simulacrum, nia-e

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue. labels Aug 11, 2026
@clarfonthey clarfonthey removed O-windows Operating system: Windows O-unix Operating system: Unix-like O-apple Operating system: Apple / Darwin (macOS, iOS, tvOS, visionOS, watchOS) labels Aug 11, 2026
@rustbot rustbot added O-apple Operating system: Apple / Darwin (macOS, iOS, tvOS, visionOS, watchOS) O-unix Operating system: Unix-like O-windows Operating system: Windows labels Aug 11, 2026
@rustbot

This comment has been minimized.

@clarfonthey
clarfonthey force-pushed the byte-str-module branch 2 times, most recently from 78405db to 5adccc5 Compare August 11, 2026 14:20
@clarfonthey clarfonthey changed the title Rename bstr module to byte_str Rename bstr module/feature to byte_str Aug 11, 2026
@rust-log-analyzer

This comment has been minimized.

@theemathas

Copy link
Copy Markdown
Contributor

Can we also have a doc alias or something, so when someone searches for bstr (like the crate name), they also find this?

@clarfonthey

clarfonthey commented Aug 11, 2026 •

Copy link
Copy Markdown
Contributor Author

Thank you for reminding me; I'll add those to the types and the module.

EDIT: The types already have it, so, just the module, then.

@clarfonthey
clarfonthey force-pushed the byte-str-module branch 2 times, most recently from 1d7938e to 3c4fe83 Compare August 11, 2026 17:21
@rust-log-analyzer

This comment has been minimized.

@clarfonthey

Copy link
Copy Markdown
Contributor Author

Yeah, okay, since the types have this, adding it to the modules is just extra noise:

module bstr - see std::byte_str, struct BStr - see std::byte_str::ByteStr, module bstr - see alloc::byte_str, module bstr - see core::byte_str, struct BString - see std::byte_str::ByteString

@clarfonthey

Copy link
Copy Markdown
Contributor Author

Note: the rustdoc links are annoying, but I'll finagle a fix for them.

@rust-log-analyzer

This comment has been minimized.

@Mark-Simulacrum

Copy link
Copy Markdown
Member

I assume there's a "why" somewhere for this, can you expand the PR description to include it? The actual code changes seem fine (I guess modulo CI failure :)

@rust-bors

This comment was marked as outdated.

@clarfonthey clarfonthey added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-blocked Status: Blocked on something else such as an RFC or other implementation work. labels Oct 3, 2026
@rust-log-analyzer

This comment has been minimized.

@clarfonthey

Copy link
Copy Markdown
Contributor Author

Ugh, fine, I guess this isn't done. @rustbot author

:|

@rustbot rustbot added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Oct 3, 2026
@rustbot

rustbot commented Oct 3, 2026

Copy link
Copy Markdown
Collaborator

Reminder, once the PR becomes ready for a review, use @rustbot ready.

@clarfonthey

Copy link
Copy Markdown
Contributor Author

@rustbot ready

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Oct 3, 2026
@Mark-Simulacrum

Copy link
Copy Markdown
Member

I think #160912 (comment) is still unresolved -- this should have some motivation in the PR description :)

@clarfonthey

clarfonthey commented Oct 3, 2026 •

Copy link
Copy Markdown
Contributor Author

Was this not sufficient?

#160912 (comment)

(Don't remember if you were there for the discussion)

Edit: you weren't, but here's the discussion: https://github.com/rust-lang/libs-team/blob/main/minutes/2026-08-25.md#nominated-rusttf160912-rename-bstr-modulefeature-to-byte_str

@clarfonthey

Copy link
Copy Markdown
Contributor Author

ping @Mark-Simulacrum to take another look when you have time

@Mark-Simulacrum

Copy link
Copy Markdown
Member

I updated the PR description so a future reader hopefully needs to hunt through less history to figure that out.

@bors r+

@rust-bors

rust-bors Bot commented Oct 18, 2026

Copy link
Copy Markdown
Contributor

📌 Commit d124e88 has been approved by Mark-Simulacrum

It is now in the queue for this repository.

@rust-bors rust-bors Bot added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Oct 18, 2026
@rust-bors

rust-bors Bot commented Oct 18, 2026 •

Copy link
Copy Markdown
Contributor

⌛ Testing commit d124e88 with merge 5e6e3df...

Workflow: https://github.com/rust-lang/rust/actions/runs/39159724762

rust-bors Bot pushed a commit that referenced this pull request Oct 18, 2026
Rename `bstr` module/feature to `byte_str`



This also renames the various features to use `byte_str` instead of `bstr`.

This was [discussed](https://github.com/rust-lang/libs-team/blob/main/minutes/2026-08-25.md#nominated-rusttf160912-rename-bstr-modulefeature-to-byte_str) by libs and agreed on as being more consistent with the types contained in the module. However, we remain open to renaming back before stabilization if warranted.

For now, `byte_str::ByteStr` makes the most sense.

(To be clear, `bstr::ByteStr` and `byte_str::BStr` are both undesired.)
@JonathanBrouwer

Copy link
Copy Markdown
Member

@bors yield
Yielding to enclosing rollup

@rust-bors

rust-bors Bot commented Oct 18, 2026

Copy link
Copy Markdown
Contributor

Auto build was cancelled. Cancelled workflows:

The next pull request likely to be tested is #164535.

rust-bors Bot pushed a commit that referenced this pull request Oct 18, 2026
…uwer

Rollup of 4 pull requests

Successful merges:

 - #160912 (Rename `bstr` module/feature to `byte_str`)
 - #164463 (perf: inline `Clause::map_bound`)
 - #163746 (consteval: Rework caller location handling)
 - #163611 (add core::process::resumable_breakpoint)
@rust-bors
rust-bors Bot merged commit cf5b0b5 into rust-lang:main Oct 18, 2026
14 of 15 checks passed
rust-bors Bot pushed a commit that referenced this pull request Oct 18, 2026
Rollup merge of #160912 - clarfonthey:byte-str-module, r=Mark-Simulacrum

Rename `bstr` module/feature to `byte_str`

This also renames the various features to use `byte_str` instead of `bstr`.

This was [discussed](https://github.com/rust-lang/libs-team/blob/main/minutes/2026-08-25.md#nominated-rusttf160912-rename-bstr-modulefeature-to-byte_str) by libs and agreed on as being more consistent with the types contained in the module. However, we remain open to renaming back before stabilization if warranted.

For now, `byte_str::ByteStr` makes the most sense.

(To be clear, `bstr::ByteStr` and `byte_str::BStr` are both undesired.)
@rustbot rustbot added this to the 1.101.0 milestone Oct 18, 2026
programskillforverification pushed a commit to programskillforverification/miri that referenced this pull request Oct 19, 2026
…uwer

Rollup of 4 pull requests

Successful merges:

 - rust-lang/rust#160912 (Rename `bstr` module/feature to `byte_str`)
 - rust-lang/rust#164463 (perf: inline `Clause::map_bound`)
 - rust-lang/rust#163746 (consteval: Rework caller location handling)
 - rust-lang/rust#163611 (add core::process::resumable_breakpoint)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

O-apple Operating system: Apple / Darwin (macOS, iOS, tvOS, visionOS, watchOS) O-unix Operating system: Unix-like O-windows Operating system: Windows S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-libs Relevant to the library team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants