Skip to content

Instantly share code, notes, and snippets.

@frenchy64
Last active August 29, 2015 14:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save frenchy64/5b88cfdfd834bfbf93ae to your computer and use it in GitHub Desktop.
Save frenchy64/5b88cfdfd834bfbf93ae to your computer and use it in GitHub Desktop.
(defprotocol Foo
(is-foo [this, a :- Number] :- Number)
(is-bar [this, a :- Int] :- Int
[this, b :- Number] :- Number)
(is-baz [this, a :- Int] :- Int
[this, a :- Int, b :- Int] :- Int
[this, a :- Int, b :- Int, c :- Int] :- Int))
(ann-protocol Foo
is-foo
[Foo Number -> Number]
is-bar
(Fn [Foo Int -> Int]
[Foo Number -> Number])
is-baz
(Fn [Foo Int -> Int]
[Foo Int Int -> Int]
[Foo Int Int Int -> Int]))
(defprotocol> Foo
(is-foo [this a])
(is-bar [this a])
(is-baz [this a]
[this a b]
[this a b c]))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment