Skip to content

Document large input behavior and compilation limits#45

Merged
leighmcculloch merged 2 commits intomainfrom
add-large-input-docs
Feb 25, 2026
Merged

Document large input behavior and compilation limits#45
leighmcculloch merged 2 commits intomainfrom
add-large-input-docs

Conversation

@leighmcculloch
Copy link
Member

What

Add documentation to the crate-level docs and both bytes! and bytesmin! macros explaining that they are intended for small inputs and that large inputs may cause long compilation times, directing users to include_bytes! as an alternative.

Why

Users encountering slow compilation with large byte literals have no guidance on expected behavior or alternatives. This makes the tradeoff explicit and points to the standard library solution.

@leighmcculloch leighmcculloch requested review from a team and Copilot February 24, 2026 10:50
@leighmcculloch leighmcculloch marked this pull request as ready for review February 24, 2026 10:50
@leighmcculloch leighmcculloch enabled auto-merge (squash) February 24, 2026 10:50
@leighmcculloch leighmcculloch enabled auto-merge (squash) February 24, 2026 10:50
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates crate and macro documentation to set expectations around compile-time cost for large literals and to point users to include_bytes! for large byte data.

Changes:

  • Added crate-level documentation noting the macros are intended for small inputs and may be slow for very large literals.
  • Added the same guidance to bytes! and bytesmin! macro docs, recommending include_bytes! for large byte payloads.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@leighmcculloch leighmcculloch merged commit 9da0973 into main Feb 25, 2026
8 checks passed
@leighmcculloch leighmcculloch deleted the add-large-input-docs branch February 25, 2026 06:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants