{"action":"created","issue":{"url":"https://api.github.com/repos/alpaca-lang/alpaca/issues/190","repository_url":"https://api.github.com/repos/alpaca-lang/alpaca","labels_url":"https://api.github.com/repos/alpaca-lang/alpaca/issues/190/labels{/name}","comments_url":"https://api.github.com/repos/alpaca-lang/alpaca/issues/190/comments","events_url":"https://api.github.com/repos/alpaca-lang/alpaca/issues/190/events","html_url":"https://github.com/alpaca-lang/alpaca/pull/190","id":240728383,"number":190,"title":"Add type signatures","user":{"login":"lepoetemaudit","id":10742921,"avatar_url":"https://avatars0.githubusercontent.com/u/10742921?v=3","gravatar_id":"","url":"https://api.github.com/users/lepoetemaudit","html_url":"https://github.com/lepoetemaudit","followers_url":"https://api.github.com/users/lepoetemaudit/followers","following_url":"https://api.github.com/users/lepoetemaudit/following{/other_user}","gists_url":"https://api.github.com/users/lepoetemaudit/gists{/gist_id}","starred_url":"https://api.github.com/users/lepoetemaudit/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lepoetemaudit/subscriptions","organizations_url":"https://api.github.com/users/lepoetemaudit/orgs","repos_url":"https://api.github.com/users/lepoetemaudit/repos","events_url":"https://api.github.com/users/lepoetemaudit/events{/privacy}","received_events_url":"https://api.github.com/users/lepoetemaudit/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2017-07-05T17:55:36Z","updated_at":"2017-07-07T17:20:22Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/alpaca-lang/alpaca/pulls/190","html_url":"https://github.com/alpaca-lang/alpaca/pull/190","diff_url":"https://github.com/alpaca-lang/alpaca/pull/190.diff","patch_url":"https://github.com/alpaca-lang/alpaca/pull/190.patch"},"body":"Adds type signatures that use the same style as type specs on ADTs, e.g.\r\n\r\n```f#\r\nval apply 'a 'b : fn (fn 'a -> 'b) 'a -> 'b\r\nlet apply f x = f x\r\n```\r\nThis also matches the syntax suggested by @danabr in https://github.com/alpaca-lang/alpaca/issues/133. There are many examples provided in https://github.com/lepoetemaudit/alpaca/blob/a70f1fc051616a376da63c65bfb313f02e8da246/test_files/basic_type_signature.alp\r\n\r\nNote that we separate function arguments only by whitespace, not by `->`, and preceded by `fn`, unlike other MLs. I believe this syntax was chosen to better reflect the fact that functions in Alpaca are multi-arity, not single argument and auto-curried (currying happens at call-site). However, as has been discussed it is possible we might support the more ML style syntax in future alongside or in place of this one."},"comment":{"url":"https://api.github.com/repos/alpaca-lang/alpaca/issues/comments/313742343","html_url":"https://github.com/alpaca-lang/alpaca/pull/190#issuecomment-313742343","issue_url":"https://api.github.com/repos/alpaca-lang/alpaca/issues/190","id":313742343,"user":{"login":"j14159","id":323681,"avatar_url":"https://avatars1.githubusercontent.com/u/323681?v=3","gravatar_id":"","url":"https://api.github.com/users/j14159","html_url":"https://github.com/j14159","followers_url":"https://api.github.com/users/j14159/followers","following_url":"https://api.github.com/users/j14159/following{/other_user}","gists_url":"https://api.github.com/users/j14159/gists{/gist_id}","starred_url":"https://api.github.com/users/j14159/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/j14159/subscriptions","organizations_url":"https://api.github.com/users/j14159/orgs","repos_url":"https://api.github.com/users/j14159/repos","events_url":"https://api.github.com/users/j14159/events{/privacy}","received_events_url":"https://api.github.com/users/j14159/received_events","type":"User","site_admin":false},"created_at":"2017-07-07T17:20:22Z","updated_at":"2017-07-07T17:20:22Z","body":"Thanks for this, have really been looking forward to it!"}}
{"actor":{"display_login":"j14159"}}