aboutsummaryrefslogtreecommitdiffstats
path: root/src/vhdl
diff options
context:
space:
mode:
Diffstat (limited to 'src/vhdl')
-rw-r--r--src/vhdl/scanner.adb7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/vhdl/scanner.adb b/src/vhdl/scanner.adb
index f91357922..8a8150b89 100644
--- a/src/vhdl/scanner.adb
+++ b/src/vhdl/scanner.adb
@@ -453,6 +453,13 @@ package body Scanner is
Error_Msg_Scan ("format effector not allowed in a string");
exit;
when Invalid =>
+ if C = Files_Map.EOT
+ and then Pos >= Current_Context.File_Len
+ then
+ Error_Msg_Scan ("string not terminated at end of file");
+ exit;
+ end if;
+
Error_Msg_Scan
("invalid character not allowed, even in a string");
when Graphic_Character =>