Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 3 additions & 6 deletions tools/coqdep/lib/lexer.mll
Original file line number Diff line number Diff line change
Expand Up @@ -132,10 +132,9 @@ and extra_dep_rule from = parse
and require_modifiers from = parse
| "(*"
{ comment lexbuf; require_modifiers from lexbuf }
| "Import" space*
{ require_file from lexbuf }
| "Export" space*
{ require_file from lexbuf }
| ("Import" | "Export") space* ("-" space*)? ((space | "(") as p)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

all those space* should be able to tolerate comments too (comments between - and ( were already bugged before this PR, but I think something like Require Import (* hints cause TC loop *) -(hints) foo would work before this PR)

{ if p = '(' then skip_parenthesized lexbuf;
require_file from lexbuf }
| space+
{ require_modifiers from lexbuf }
| eof
Expand Down Expand Up @@ -200,8 +199,6 @@ and load_file = parse
and require_file from = parse
| "(*"
{ comment lexbuf; require_file from lexbuf }
| ("-" space*)? "("
{ skip_parenthesized lexbuf; require_file from lexbuf }
| space+
{ require_file from lexbuf }
| coq_ident
Expand Down
Loading