From 1487ffaa14b36c1bc363a4684c42bd58c523cfbd Mon Sep 17 00:00:00 2001 From: Tristan Gingold Date: Fri, 3 Sep 2021 07:54:52 +0200 Subject: vhdl-scanner.adb: add comments --- src/vhdl/vhdl-scanner.adb | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/vhdl') diff --git a/src/vhdl/vhdl-scanner.adb b/src/vhdl/vhdl-scanner.adb index 603e4652b..76e6fe5fd 100644 --- a/src/vhdl/vhdl-scanner.adb +++ b/src/vhdl/vhdl-scanner.adb @@ -2011,6 +2011,8 @@ package body Vhdl.Scanner is when '*' => if Source (Pos + 1) = '/' then if Pos > Current_Context.Token_Pos then + -- There are characters before the end of comment, so + -- first return them. Current_Token := Tok_Block_Comment_Text; else Pos := Pos + 2; @@ -2022,6 +2024,8 @@ package body Vhdl.Scanner is end if; when CR => if Pos > Current_Context.Token_Pos then + -- There are characters before the CR, so + -- first return them. Current_Token := Tok_Block_Comment_Text; else Scan_CR_Newline; @@ -2030,6 +2034,8 @@ package body Vhdl.Scanner is return; when LF => if Pos > Current_Context.Token_Pos then + -- There are characters before the LF, so + -- first return them. Current_Token := Tok_Block_Comment_Text; else Scan_LF_Newline; -- cgit v1.2.3