{"action":"created","issue":{"url":"https://api.github.com/repos/scalaz/scalaz/issues/968","labels_url":"https://api.github.com/repos/scalaz/scalaz/issues/968/labels{/name}","comments_url":"https://api.github.com/repos/scalaz/scalaz/issues/968/comments","events_url":"https://api.github.com/repos/scalaz/scalaz/issues/968/events","html_url":"https://github.com/scalaz/scalaz/issues/968","id":92738161,"number":968,"title":"Missing withFilter in for comprehensions","user":{"login":"TomasMikula","id":433439,"avatar_url":"https://avatars.githubusercontent.com/u/433439?v=3","gravatar_id":"","url":"https://api.github.com/users/TomasMikula","html_url":"https://github.com/TomasMikula","followers_url":"https://api.github.com/users/TomasMikula/followers","following_url":"https://api.github.com/users/TomasMikula/following{/other_user}","gists_url":"https://api.github.com/users/TomasMikula/gists{/gist_id}","starred_url":"https://api.github.com/users/TomasMikula/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TomasMikula/subscriptions","organizations_url":"https://api.github.com/users/TomasMikula/orgs","repos_url":"https://api.github.com/users/TomasMikula/repos","events_url":"https://api.github.com/users/TomasMikula/events{/privacy}","received_events_url":"https://api.github.com/users/TomasMikula/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-07-02T21:19:45Z","updated_at":"2015-07-02T21:24:29Z","closed_at":null,"body":"The following definition\r\n\r\n```scala\r\ndef foo[A, B](m: Maybe[(A, B)]): Maybe[A] =\r\n  for {\r\n    (a, b) <- m\r\n  } yield a\r\n```\r\n\r\ndoes not compile with the following error:\r\n\r\n     value withFilter is not a member of scalaz.Maybe[(A, B)]\r\n\r\nCan/should this be fixed?\r\n\r\nThe workaround is\r\n\r\n```scala\r\ndef foo[A, B](m: Maybe[(A, B)]): Maybe[A] =\r\n  for {\r\n    ab <- m\r\n    (a, b) = ab\r\n  } yield a\r\n```\r\n\r\nThere is the same problem with other scalaz monads."},"comment":{"url":"https://api.github.com/repos/scalaz/scalaz/issues/comments/118172270","html_url":"https://github.com/scalaz/scalaz/issues/968#issuecomment-118172270","issue_url":"https://api.github.com/repos/scalaz/scalaz/issues/968","id":118172270,"user":{"login":"vmarquez","id":427578,"avatar_url":"https://avatars.githubusercontent.com/u/427578?v=3","gravatar_id":"","url":"https://api.github.com/users/vmarquez","html_url":"https://github.com/vmarquez","followers_url":"https://api.github.com/users/vmarquez/followers","following_url":"https://api.github.com/users/vmarquez/following{/other_user}","gists_url":"https://api.github.com/users/vmarquez/gists{/gist_id}","starred_url":"https://api.github.com/users/vmarquez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vmarquez/subscriptions","organizations_url":"https://api.github.com/users/vmarquez/orgs","repos_url":"https://api.github.com/users/vmarquez/repos","events_url":"https://api.github.com/users/vmarquez/events{/privacy}","received_events_url":"https://api.github.com/users/vmarquez/received_events","type":"User","site_admin":false},"created_at":"2015-07-02T21:24:29Z","updated_at":"2015-07-02T21:24:29Z","body":"So there's this:\r\n\r\nhttps://github.com/scalaz/scalaz/pull/922 which references https://github.com/scalaz/scalaz/pull/728\r\n\r\nBut as you can see in 728, @puffnfresh pointed out that this behavior can actually cause scalac to lose some type safety! \r\n\r\nHere's an example: https://github.com/scalaz/scalaz/pull/728#issuecomment-45779363"}}