{"action":"created","issue":{"url":"https://api.github.com/repos/fsprojects/FsUnit/issues/47","repository_url":"https://api.github.com/repos/fsprojects/FsUnit","labels_url":"https://api.github.com/repos/fsprojects/FsUnit/issues/47/labels{/name}","comments_url":"https://api.github.com/repos/fsprojects/FsUnit/issues/47/comments","events_url":"https://api.github.com/repos/fsprojects/FsUnit/issues/47/events","html_url":"https://github.com/fsprojects/FsUnit/issues/47","id":47213609,"number":47,"title":"is there a better way to match against patterns?","user":{"login":"theburningmonk","id":546969,"avatar_url":"https://avatars.githubusercontent.com/u/546969?v=3","gravatar_id":"","url":"https://api.github.com/users/theburningmonk","html_url":"https://github.com/theburningmonk","followers_url":"https://api.github.com/users/theburningmonk/followers","following_url":"https://api.github.com/users/theburningmonk/following{/other_user}","gists_url":"https://api.github.com/users/theburningmonk/gists{/gist_id}","starred_url":"https://api.github.com/users/theburningmonk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/theburningmonk/subscriptions","organizations_url":"https://api.github.com/users/theburningmonk/orgs","repos_url":"https://api.github.com/users/theburningmonk/repos","events_url":"https://api.github.com/users/theburningmonk/events{/privacy}","received_events_url":"https://api.github.com/users/theburningmonk/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2014-10-29T22:46:30Z","updated_at":"2016-02-29T05:51:21Z","closed_at":null,"body":"Right now, I'm using a `match ... with` clause with the pattern I want (e.g. I don't care about all the items in a tuple) manually.\r\n```\r\n    match f() with\r\n    | _, _, _, 42 -> true\r\n    | _ -> false\r\n    |> should equal true\r\n```\r\nwhich is very clumsy. Is there a better way to do this currently?\r\n\r\nIn Eunit, I'd use [?assertMatch](http://www.erlang.org/doc/apps/eunit/chapter.html#Assert_macros) which uses macros (which we don't have in F#), is there some way to achieve the same effect in F#?"},"comment":{"url":"https://api.github.com/repos/fsprojects/FsUnit/issues/comments/190056411","html_url":"https://github.com/fsprojects/FsUnit/issues/47#issuecomment-190056411","issue_url":"https://api.github.com/repos/fsprojects/FsUnit/issues/47","id":190056411,"user":{"login":"sergey-tihon","id":1197905,"avatar_url":"https://avatars.githubusercontent.com/u/1197905?v=3","gravatar_id":"","url":"https://api.github.com/users/sergey-tihon","html_url":"https://github.com/sergey-tihon","followers_url":"https://api.github.com/users/sergey-tihon/followers","following_url":"https://api.github.com/users/sergey-tihon/following{/other_user}","gists_url":"https://api.github.com/users/sergey-tihon/gists{/gist_id}","starred_url":"https://api.github.com/users/sergey-tihon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sergey-tihon/subscriptions","organizations_url":"https://api.github.com/users/sergey-tihon/orgs","repos_url":"https://api.github.com/users/sergey-tihon/repos","events_url":"https://api.github.com/users/sergey-tihon/events{/privacy}","received_events_url":"https://api.github.com/users/sergey-tihon/received_events","type":"User","site_admin":false},"created_at":"2016-02-29T05:51:21Z","updated_at":"2016-02-29T05:51:21Z","body":"Can you propose better syntax ?\r\n\r\n```fsharp\r\nmatch f() with\r\n    | _, _, _, 42 -> \r\n      true |> should equal true\r\n    | _ -> failwith \"unexpected result\"\r\n```"}}