1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-29 04:07:34 +00:00

AK: Update OptionParser::m_arg_index by substracting skipped args

On argument swapping to put positional ones toward the end,
m_arg_index was pointing at "last arg  index" + "skipped args" +
"consumed args" and thus was pointing ahead of the skipped ones.

m_arg_index now points after the current parsed option arguments.
This commit is contained in:
vincent-rg 2024-02-05 21:47:09 +01:00 committed by Ali Mohammad Pur
parent 8320faf052
commit a9df60ff1c
5 changed files with 382 additions and 2 deletions

View file

@ -56,6 +56,7 @@ set(AK_TEST_SOURCES
TestNonnullRefPtr.cpp
TestNumberFormat.cpp
TestOptional.cpp
TestOptionParser.cpp
TestOwnPtr.cpp
TestPrint.cpp
TestQueue.cpp