core.typed

Annotation for re-find return type is too specific

Details

  • Type: Enhancement Enhancement
  • Status: Closed Closed
  • Priority: Minor Minor
  • Resolution: Completed
  • Affects Version/s: None
  • Fix Version/s: None
  • Component/s: None
  • Labels:
    None

Description

clojure.core/re-find returns different things depending on the regular expression used and the string it matches against. Currently core.typed annotates this as returning (Option String). However, in the presence of capture groups, it may return a vector of strings, so the current annotation is too specific.

Additionally, clojure.core/re-groups is not annotated, and uses the same return type as clojure.core/re-find.

Activity

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: