Right now it's possible to declare multiple clauses for `@spec` as we can see in
Typespecs documentation, but we don't have the same feature for `@type` and `@typep`.
Since `@spec` allows for it, one -- me, actually -- would think the same could be done to `@type(p)`. Here's a silly example for when this would be helpful:
```
@type error_details(t) :: {:invalid, :invalid_atom, term} when t: atom
@type error_details(t) :: {:invalid, :invalid_boolean, term} when t: binary
@type error_details(t) :: {:invalid, :invalid_whatever, term} when t: user_custom_type
@spec foo(atom) :: {:ok, binary} | {:error, error(atom)
@spec foo(binary) :: {:ok, binary} | {:error, error(binary)
@spec foo(user_custom_type) :: {:ok, binary} | {:error, error(user_custom_type)
def foo(value)
```
IMO, having this feature for `@type` (prob for `@typep` as well, just for consistency) is complementary to multiple `@spec` clauses, allowing for reuse of typespecs.
-