Skip to content

Commit

Permalink
refined regexp match
Browse files Browse the repository at this point in the history
  • Loading branch information
vzaliva committed Sep 25, 2016
1 parent aa497f7 commit 813aa21
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion Test.v
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
Require Import Bool.DecBool.
Require Import Arith.Min.
Require Import Omega. (* comment *)
Require Import BinNums List Setoid.
Require Import BinNums Coq.List Setoid.
Require Import Setoid. (* Presently for testing only. Consider moving it elsewhere *)

(* requires Arith.Min *)
Definition bar1 := min_0_l.
Expand Down
2 changes: 1 addition & 1 deletion coq_min_imports.ml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ open BatIO
open Dirtools

(* TODO: match mutliline import statements *)
let import_regexp = Str.regexp "^[ \t]*Require[ \t]+Import[ \t]+\\(.+\\)\\.[\t ]*"
let import_regexp = Str.regexp "^[ \t]*Require[ \t]+Import[ \t]+\\(\\([A-Za-z_\\.]+\\)\\([ \t]+[A-Za-z_\\.]+\\)*\\)\\."

let verbose = ref false
let replace = ref false
Expand Down

0 comments on commit 813aa21

Please sign in to comment.