{"action":"created","issue":{"url":"https://api.github.com/repos/racket/typed-racket/issues/208","labels_url":"https://api.github.com/repos/racket/typed-racket/issues/208/labels{/name}","comments_url":"https://api.github.com/repos/racket/typed-racket/issues/208/comments","events_url":"https://api.github.com/repos/racket/typed-racket/issues/208/events","html_url":"https://github.com/racket/typed-racket/issues/208","id":109641505,"number":208,"title":"Occurrence typing: Advanced filters (e.g. for `positive?`) kept secret","user":{"login":"Blaisorblade","id":289960,"avatar_url":"https://avatars.githubusercontent.com/u/289960?v=3","gravatar_id":"","url":"https://api.github.com/users/Blaisorblade","html_url":"https://github.com/Blaisorblade","followers_url":"https://api.github.com/users/Blaisorblade/followers","following_url":"https://api.github.com/users/Blaisorblade/following{/other_user}","gists_url":"https://api.github.com/users/Blaisorblade/gists{/gist_id}","starred_url":"https://api.github.com/users/Blaisorblade/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Blaisorblade/subscriptions","organizations_url":"https://api.github.com/users/Blaisorblade/orgs","repos_url":"https://api.github.com/users/Blaisorblade/repos","events_url":"https://api.github.com/users/Blaisorblade/events{/privacy}","received_events_url":"https://api.github.com/users/Blaisorblade/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-10-03T19:46:57Z","updated_at":"2015-10-03T19:55:46Z","closed_at":null,"body":"When looking at a function type, (some?) filters which can't be expressed with just `:` are not shown without warning, making it hard to understand how occurrence typing works. This is also not documented, so I'm not sure if there's any rationale, but I can only imagine verbosity or complexity of the signature.\r\n\r\nHowever, such filters are never shown, even when using `#:verbose`, and I'm confident that's bad — how can I understand what the typechecker is doing if signatures are hidden?\r\n\r\nMoreover, even if you want to hide part of a type by default, there should be some warning to the user. So for `positive?`, Typed Racket shouldn't show `(-> Real Boolean)` but sth. like `(-> Real Boolean ...)`, and docs should explain that `...` means \"there's more you're not seeing\". (No clue if `...` is a decent idea as concrete syntax, you can figure that out).\r\n\r\n```racket\r\n> string?\r\n- : (-> Any Boolean : String)\r\n#<procedure:string?>\r\n> positive?\r\n- : (-> Real Boolean)\r\n#<procedure:positive?>\r\n> (:type (-> Real Boolean : #:+ Positive-Real #:- Nonpositive-Real))\r\n(-> Real Boolean)\r\n[can expand further: Boolean Real]\r\n> (:type #:verbose (-> Real Boolean : #:+ Positive-Real #:- Nonpositive-Real))\r\n(-> (U 0\r\n       1\r\n       Byte-Larger-Than-One\r\n       Positive-Index-Not-Byte\r\n       Positive-Fixnum-Not-Index\r\n       Negative-Fixnum\r\n       Positive-Integer-Not-Fixnum\r\n       Negative-Integer-Not-Fixnum\r\n       Positive-Rational-Not-Integer\r\n       Negative-Rational-Not-Integer\r\n       Float-Nan\r\n       Float-Positive-Zero\r\n       Float-Negative-Zero\r\n       Positive-Float-No-NaN\r\n       Negative-Float-No-NaN\r\n       Single-Flonum-Nan\r\n       Single-Flonum-Positive-Zero\r\n       Single-Flonum-Negative-Zero\r\n       Positive-Single-Flonum-No-Nan\r\n       Negative-Single-Flonum-No-Nan)\r\n    (U #f #t))\r\n```"},"comment":{"url":"https://api.github.com/repos/racket/typed-racket/issues/comments/145282032","html_url":"https://github.com/racket/typed-racket/issues/208#issuecomment-145282032","issue_url":"https://api.github.com/repos/racket/typed-racket/issues/208","id":145282032,"user":{"login":"Blaisorblade","id":289960,"avatar_url":"https://avatars.githubusercontent.com/u/289960?v=3","gravatar_id":"","url":"https://api.github.com/users/Blaisorblade","html_url":"https://github.com/Blaisorblade","followers_url":"https://api.github.com/users/Blaisorblade/followers","following_url":"https://api.github.com/users/Blaisorblade/following{/other_user}","gists_url":"https://api.github.com/users/Blaisorblade/gists{/gist_id}","starred_url":"https://api.github.com/users/Blaisorblade/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Blaisorblade/subscriptions","organizations_url":"https://api.github.com/users/Blaisorblade/orgs","repos_url":"https://api.github.com/users/Blaisorblade/repos","events_url":"https://api.github.com/users/Blaisorblade/events{/privacy}","received_events_url":"https://api.github.com/users/Blaisorblade/received_events","type":"User","site_admin":false},"created_at":"2015-10-03T19:55:46Z","updated_at":"2015-10-03T19:55:46Z","body":"Thanks to @AlexKnauth for at least explaining me what was going on on racket-users (https://groups.google.com/d/msg/racket-users/vU1DtzTBhLg/iuWXPHDPAAAJ)."}}