This patch inverses the values returned by addName and
lookup methods of the class mentioned so that they
now return true on success and false on failure.
Also, it does minor code cleanup.
Details
Diff Detail
Event Timeline
I'm happy with this in principle, but I do wonder how you made sure you caught all instances!
tools/yaml2obj/yaml2elf.cpp | ||
---|---|---|
78 | As you're tidying this comment up, please change "asserts" to "Asserts". | |
400 | What happens if you specify a section name that doesn't exist? Does this result in an assertion? If so, we should produce an actual error instead in this case. Similar point may apply below. |
I am usually using renaming magic for such things. I.e. I renamed addName to addName1, lookup to lookup1 and so on,
then tried to compile and fixed all the places. Then renamed back.
tools/yaml2obj/yaml2elf.cpp | ||
---|---|---|
400 | Oh, I did not notice we do not fail if list a section that do not exist. I think we should check it earlier than here then. |
LGTM.
tools/yaml2obj/yaml2elf.cpp | ||
---|---|---|
78 | Not sure if those are necessary or not due to doxygen! |
As you're tidying this comment up, please change "asserts" to "Asserts".