platform_build_blueprint/parser
Colin Cross eb15c126c3 Fix numericStringLess and add tests
numericStringLess("1a", "11a") would strip the equal prefix "1" and
then compare the bytes "a" and "1", when it should have compared the
numbers 1 and 11.  Fix it by handling the case where the last equal
byte was numeric and the first differing byte is numeric in one
string and non-numeric in the other.

numericStringLess("12", "101") would strip the equal prefix "1" and
then compare the numbers 2 and 01, when it should have compared the
numbers 12 and 101.  Fix it by tracking the beginning of the sequence
of numeric bytes containing the differing byte.

Test: sort_test.go
Change-Id: I8d9252a64625ba6a3c75d09bb1429dcb1115e3e1
2021-03-08 17:59:55 -08:00
..
ast.go Implement list of maps 2020-03-02 17:26:20 -08:00
modify.go Add Patch and PatchList for making textual changes 2018-04-10 16:50:39 -07:00
modify_test.go Add Patch and PatchList for making textual changes 2018-04-10 16:50:39 -07:00
parser.go Implement list of maps 2020-03-02 17:26:20 -08:00
parser_test.go Implement list of maps 2020-03-02 17:26:20 -08:00
printer.go Improve indentation for multi-line expressions 2018-05-07 16:15:33 -07:00
printer_test.go Implement list of maps 2020-03-02 17:26:20 -08:00
sort.go Fix numericStringLess and add tests 2021-03-08 17:59:55 -08:00
sort_test.go Fix numericStringLess and add tests 2021-03-08 17:59:55 -08:00