Kiln » babybearparser
Clone URL:  
Pushed to one repository · View In Graph Contained in tip

[review K121041] Parser.fs: more idiomatic F#.

Changeset 876e4bb434dc

Parent 3fa00e44c464

by Profile picture of User 138Hao Lian <hao@fogcreek.com>

Changes to one file · Browse files at 876e4bb434dc Showing diff from parent 3fa00e44c464 Diff from another changeset...

 
33
34
35
36
37
 
 
38
39
40
 
33
34
35
 
 
36
37
38
39
40
@@ -33,8 +33,8 @@
  | Some x -> preturn x   | None -> fail msg  let stringToDate = function - | "today" -> Some DateTime.UtcNow.Date - | "yesterday" -> Some <| DateTime.UtcNow.Date.AddDays(-1.) + | "today" -> DateTime.UtcNow.Date |> Some + | "yesterday" -> DateTime.UtcNow.Date.AddDays -1. |> Some   | s -> try DateTime.Parse s |> Some with :? FormatException -> None  let findFilter = function   | "author" -> Author