> On 23 Dec 2013, at 8:40 pm, [email protected] wrote: > > > I think that ghdl is compliant with VHDL 1993 and 2002. That's > > modulo > > bugs, but I think that all features are implemented. If not, do > > not > > hesitate to raise issues. > > > entity label_test is > generic (MODE: natural range 0 to 1 := 1); > end entity; > > architecture fum of label_test is > begin > if_label: > if MODE = 1 then > end if; > end architecture; > > david_koontz@Macbook: ghdl -a label_test.vhdl > label_test.vhdl:8:16: 'generate' is expected instead of 'then' > ghdl: compilation error > > However: > > entity no_label_test is > generic (MODE: natural range 0 to 1 := 1); > end entity; > > architecture fum of no_label_test is > begin > if MODE = 1 then > end if; > end architecture; > > david_koontz@Macbook: ghdl -a no_label_test.vhdl > no_label_test.vhdl:7:4: a generate statement must have a label > no_label_test.vhdl:7:16: 'generate' is expected instead of 'then' > ghdl: compilation error
[...] > > The particular case leading to no_label_test comes from a VHDL > neophyte asking what was wrong with his code, attempting to use a > sequential (if) statement in a place appropriate for a concurrent > statement, then noticing significant disparity in how the error was > reported by various VHDL tools. > > And it does represent non-compliant behaviour. No. While I agree that the error message could be improved, ghdl correctly rejects both units. The VHDL standards says nothing about the error messages. It just says what is a correct unit and what isn't. That's being said, feel free to open a ticket so that this issue kept recorded. Tristan. _______________________________________________ Ghdl-discuss mailing list [email protected] https://mail.gna.org/listinfo/ghdl-discuss
