clojure.core/re-matcher¶
Returns an instance of java.util.regex.Matcher, for use, e.g. in re-find.
Examples¶
Note by r4um¶
17:44 < mearnsh> tsdh: re-matcher should be avoided because the Matcher object it returns mutates in a non-thread-safe way
Note by timmc¶
It's fine to use from a controlled context. For instance, if you have a let that creates a Matcher, pulls out groups, and returns the data, you're working in a single-threaded context and the mutable object never even escapes.
See also¶
Content from the matching ClojureDocs page, with authors credited on each contribution.