On 07.11.2023 11:33, Nicola Vetrini wrote: > This series is aimed at presenting some strategies that can be used to deal > with > violations of Rule 15.2: > "The goto statement shall jump to a label declared later in the same > function".
I don't recall this rule being discussed on any of the meetings. > The rule's rationale is about possible developer confusion, therefore it could > be argued that there is no substantial gain in complying with it, given the > torough review process in place. To be honest, forward goto have potential of developer confusion as well: All other entities need to be declared / defined before they can be used. Just labels don't. (Or have I missed any other outlier?) IOW if I saw Misra make any rule here, I think it ought to suggest to avoid using "goto" altogether. Jan