Skip to content
Snippets Groups Projects
Commit 5569648c authored by Lyndon Brown's avatar Lyndon Brown Committed by Hugo Beauzée-Luyssen
Browse files

config: add and use index-of helpers for cat/subcat array iteration

these 'index-of' helpers find the index for the given cat/subcat. this
allows us to de-duplicate the code from the other helper functions (both
for those that already exist and ones to be added in further commits).
they loop based upon array length rather than looking out for some
particular condition of varying properties in an end marker record,
allowing us to also drop those.

i used an index-of design here rather than have functions that return
pointers because there will be a secondary use for index-of helpers in
later commits.
parent e9edfd60
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment