Remove duplicate whitespace validation in buildtable.pl #2014

pull maradini77 wants to merge 1 commits into bitcoin:master from maradini77:patch-1 changing 1 files +0 −1
  1. maradini77 commented at 11:33 am on October 21, 2025: none

    Summary

    Removes duplicate validation logic for leading whitespace in field values in scripts/buildtable.pl.

    Changes

    • Removed redundant $val =~ /^\s/ check inside the field parsing branch
    • Kept the unified validation after branching logic
    • Maintains identical error detection behavior

    Rationale

    The same whitespace validation was performed twice:

    1. Inside the first parsing branch
    2. After the branching logic
  2. Update buildtable.pl b36478db57
  3. jonatack commented at 4:33 pm on October 21, 2025: member
    @maradini77 Thank you for your proposal. While this check line 149 is indeed a subset of the cases checked by line 158 further down, keeping it may ease debugging a failure. If removed, all leading whitespace errors in values would return “Extra spaces,” making it harder to quickly see on a batch of files whether the issue is in a new field intro or a continuation line. So let’s leave it as-is.
  4. jonatack closed this on Oct 21, 2025


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bips. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2025-10-27 15:10 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me