Created
June 5, 2011 02:21
-
-
Save nagat01/1008584 to your computer and use it in GitHub Desktop.
$ with RegexOptions.Multiline does not work for verbatim string's end of lines
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// $ with RegexOptions.Multiline does not work for verbatim string's end of lines | |
open System | |
open System.Text.RegularExpressions | |
let matchEndOfLineWord = | |
let regex = new Regex("\w+$",RegexOptions.Multiline) | |
regex.Matches("Yuki Nagato\nHaruhi Suzumiy\nMikuru Asahina") | |
|>printfn"%A" | |
regex.Matches(@"Kyon | |
Koizumi | |
Kunikida") | |
|>printfn"%A" | |
matchEndOfLineWord | |
(* | |
seq [Nagato; Suzumiy; Asahina] | |
seq [Kunikida] | |
*) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment