Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Browse files

fixes types of groups and all to include (Option String) in vectors.

Groups defined in a pattern that are part of an alternation may not capture anything and will result in a nil value being captured. The types need to reflect this
  • Loading branch information...
commit a04a12819004ae4da0eaba8805c3c6aa0dccd6f1 1 parent 7da39d5
@brehaut authored
Showing with 3 additions and 3 deletions.
  1. +3 −3 src/re/typed.clj
6 src/re/typed.clj
@@ -55,9 +55,9 @@
(ann groups
- (Fn [Matcher -> (IPersistentVector String)]
+ (Fn [Matcher -> (IPersistentVector (Option String))]
[Matcher (U (Value 0) (Value 1)) ->
- (IPersistentVector String)]))
+ (IPersistentVector (Option String))]))
(defn groups
([^Matcher m min]
@@ -72,7 +72,7 @@
(ann all
- [Matcher -> (IPersistentVector String)])
+ [Matcher -> (IPersistentVector (Option String))])
(defn all [^Matcher m]
(groups m 0))
Please sign in to comment.
Something went wrong with that request. Please try again.