elixir-lang/elixir — pull request #2281 by bitwalker (2014-05-14 03:37:41+00:00)
Title: Add typespecs for builtins, __record__, and __struct__

I've been working with the erl compiler flag `warn_missing_spec`, and things get super noisy because a handful of builtin functions don't have typespecs. These specs aren't meant to be super useful, though they should be at least roughly accurate - they're mostly intended to silence the warnings and prevent dialyzer from complaining about their usages. If you'd like me to tighten up the specs, let me know which ones, and what specificity you'd like to see.

Good times learning about the deep underbelly of Elixir's compiler though :)

Added typespecs for:

- __FILE__/1
- __MODULE__/1
- __info__/1
- __record__/1, __record__/2, __record__/3
- __struct__/0
- exception/1, exception/2