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

Fix to_chars_static buffer size #1026

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Commits on May 27, 2022

  1. Fix broken buffer estimator in to_chars_static

    - assumed decimal
    - sometimes got it wrong
    - potentially got it badly wrong
    - now uses lookup table to ensure the right number of characters to
      represent in integer of a given number of binary digits
    - table generator: https://godbolt.org/z/sYc7v185T
    - correctness: ~95%
    - probably of causing buffer overrun: < 1%
    John McFarlane committed May 27, 2022
    Configuration menu
    Copy the full SHA
    afb27d5 View commit details
    Browse the repository at this point in the history
  2. breakit

    John McFarlane committed May 27, 2022
    Configuration menu
    Copy the full SHA
    e5a6d2c View commit details
    Browse the repository at this point in the history