- Add
Result
type example in tests.
- Binding non guarded variables to expressions just replaces those vars.
- Add union patterns with examples for
nats
,maybe
,either
, struct. - Report lines at expansion point not as pattern definition line.
- nil values were not able to be bound.
- vars should be made unique on each expansion.
- guarded vars were being counted first
- Add HOW_IT_WORKS.md to add some details on how guards are expanded.
- Add bang
!
macro for named pattern that can be used as constructor.
- Pattern variables starting with
_
were able to be bound.
- Allow positional arguments in adition to named bindings.
- Document generated macros
- Support
expat with
- Added a usage guide in README.md
- Ensure pattern expassion happens in all arguments of a
def
- Major rewrite to let
defpat
support guards being defined on it - Introduced
expat
to expand patterns inside Elixir expressions
-
Removed the
...
syntax that introduced all pattern variables into scope. Now you must be explicit on what variables you want to bind. -
Removed passing
_
to ignore all variables in pattern, now you must use the macro generated with zero arity, or bind all vars to_