Skip to content

Write the large integers in tools/measure_body.exs with digit separators - #86

Open
olehgerus wants to merge 1 commit into
ScriptKittyOS:mainfrom
olehgerus:measure-body-digit-separators
Open

olehgerus wants to merge 1 commit into
ScriptKittyOS:mainfrom
olehgerus:measure-body-digit-separators

Conversation

@olehgerus

@olehgerus olehgerus commented Oct 14, 2026 •

Copy link
Copy Markdown

tools/measure_body.exs wrote 65536 (line 44) and 16384 and 65536 (line 90) without digit separators, and mix credo --strict tools/measure_body.exs reported them: "3 mods/funs, found 3 code readability issues." They now read 65_536 and 16_384, as the same list already writes 262_144 and 1_048_576. The values do not change, so the script measures what it measured before.

After: credo finds no issues on the file and mix format --check-formatted passes. Tooling-only, no CHANGELOG entry. Local gate (OTP 28.1.1 / Elixir 1.18.4): fifteen of sixteen steps pass. The test step fails on an unmodified main on this machine too, on a different timing-sensitive test each run, and each passes alone. Closes #76.

65536 and 16384 were the only integers over 9999 in the file without
underscores; the same list already writes 262_144 and 1_048_576. The values
do not change. Closes ScriptKittyOS#76.

Before, `mix credo --strict tools/measure_body.exs`:

    [R] Numbers larger than 9999 should be written with underscores: 65_536
        tools/measure_body.exs:90:34
    [R] Numbers larger than 9999 should be written with underscores: 16_384
        tools/measure_body.exs:90:27
    [R] Numbers larger than 9999 should be written with underscores: 65_536
        tools/measure_body.exs:44:27
    3 mods/funs, found 3 code readability issues.

After: "3 mods/funs, found no issues." `mix format --check-formatted
tools/measure_body.exs` passes.

Signed-off-by: Oleh Gerus <73129739+olehgerus@users.noreply.github.com>
@olehgerus
olehgerus marked this pull request as ready for review October 14, 2026 09:48
@olehgerus
olehgerus requested a review from HackTuah as a code owner October 14, 2026 09:48
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.

Write the large numbers in tools/measure_body.exs with underscores

1 participant