I tried to generate ADC yaml's for stm32wle5 but it failed when chiptool wasn't able to follow the derivedFrom directive used in the svd.
This PR tries to resolve the derivedFrom by initially creating a map of all enums. And upon reaching a derivedFrom picking the enum values from that map, if known.
Note that it ignores if there are enums which are not unique by name in the config, though looking at stm32-rs scripts I got the impression that they ignored this too.
I tried to generate ADC yaml's for stm32wle5 but it failed when chiptool wasn't able to follow the
derivedFrom
directive used in the svd.This PR tries to resolve the
derivedFrom
by initially creating a map of all enums. And upon reaching aderivedFrom
picking the enum values from that map, if known.Note that it ignores if there are enums which are not unique by name in the config, though looking at stm32-rs scripts I got the impression that they ignored this too.