aboutsummaryrefslogtreecommitdiff
path: root/libiberty
diff options
context:
space:
mode:
authorGaius Mulley <gaiusmod2@gmail.com>2024-03-28 16:49:44 +0000
committerGaius Mulley <gaiusmod2@gmail.com>2024-03-28 16:49:44 +0000
commitaeee63ffbf4f4fbc4d90d8aae808d6b67f0148a3 (patch)
treea71ed1e4ac49dd8c3501832b193fe5d6aebe88c3 /libiberty
parent04799f03e8d01b903295ef3a100a0117b7ddbf5e (diff)
downloadgcc-aeee63ffbf4f4fbc4d90d8aae808d6b67f0148a3.zip
gcc-aeee63ffbf4f4fbc4d90d8aae808d6b67f0148a3.tar.gz
gcc-aeee63ffbf4f4fbc4d90d8aae808d6b67f0148a3.tar.bz2
PR modula2/114520 Incorrect ordering of import/export statements cause confusion
The error recovery causes misleading error messages to appear if an EXPORT and IMPORT statement are in the wrong order. This patch detects the incorrect order and issues an error message and prevents error recovery. The fix should be improved and made more general if another similar case is required. gcc/m2/ChangeLog: PR modula2/114520 * gm2-compiler/P0SyntaxCheck.bnf (DetectImport): New procedure. (EnableImportCheck): New boolean. (Expect): Call DetectImport. (Export): Set EnableImportCheck TRUE before ';' and FALSE afterwards. Signed-off-by: Gaius Mulley <gaiusmod2@gmail.com>
Diffstat (limited to 'libiberty')
0 files changed, 0 insertions, 0 deletions