aboutsummaryrefslogtreecommitdiff
path: root/libiberty/simple-object-xcoff.c
diff options
context:
space:
mode:
authorGaius Mulley <gaiusmod2@gmail.com>2025-01-13 14:40:43 +0000
committerGaius Mulley <gaiusmod2@gmail.com>2025-01-13 14:40:43 +0000
commit7cd4de65ffb3f34d6ba5af2f9570900fecd7bed0 (patch)
treebd46f45739c7010390bb996215b81d4315146474 /libiberty/simple-object-xcoff.c
parentd23d338da4d2bd581b2d3fd97785dd2c26053a92 (diff)
downloadgcc-7cd4de65ffb3f34d6ba5af2f9570900fecd7bed0.zip
gcc-7cd4de65ffb3f34d6ba5af2f9570900fecd7bed0.tar.gz
gcc-7cd4de65ffb3f34d6ba5af2f9570900fecd7bed0.tar.bz2
PR modula2/118453: Subranges types do not use virtual tokens during construction
P2SymBuild.mod.BuildSubrange does not use a virtual token and therefore any error message containing a subrange type produces poor location carots. This patch rewrites BuildSubrange and the buildError4 procedure in M2Check.mod (which is only called when there is a formal/actual parameter mismatch). buildError4 now issues a sub error for the formal and actual type declaration highlighing the type mismatch. gcc/m2/ChangeLog: PR modula2/118453 * gm2-compiler/M2Check.mod (buildError4): Call MetaError1 for the actual and formal parameter type. * gm2-compiler/P2Build.bnf (SubrangeType): Construct a virtual token containing the subrange type declaration. (PrefixedSubrangeType): Ditto. * gm2-compiler/P2SymBuild.def (BuildSubrange): Add tok parameter. * gm2-compiler/P2SymBuild.mod (BuildSubrange): Use tok parameter, rather than the token at the start of the subrange. gcc/testsuite/ChangeLog: PR modula2/118453 * gm2/pim/fail/badbecomes2.mod: New test. * gm2/pim/fail/badparamset1.mod: New test. * gm2/pim/fail/badparamset2.mod: New test. * gm2/pim/fail/badsyntaxset1.mod: New test. Signed-off-by: Gaius Mulley <gaiusmod2@gmail.com>
Diffstat (limited to 'libiberty/simple-object-xcoff.c')
0 files changed, 0 insertions, 0 deletions