Permalink
Browse files

Merge pull request #10 from spawngrid/nil-record-default

Prevent seresye_engine rule addition from choking on {nil, Line} default...
  • Loading branch information...
2 parents af019ca + d2e0f22 commit 80bde8bad9e07a6f81c62e41c72d2522ff675677 @ericbmerritt ericbmerritt committed Feb 1, 2012
Showing with 6 additions and 0 deletions.
  1. +6 −0 src/seresye_engine.erl
View
@@ -250,6 +250,12 @@ get_records([_ | Tail], Acc) ->
get_record_fields([], Acc) -> lists:reverse(Acc);
get_record_fields([{record_field, _,
+ {atom, _, FieldName}, {nil, _}}
+ | Tail],
+ Acc) ->
+ NewAcc = [{FieldName, {nil, []}} | Acc],
+ get_record_fields(Tail, NewAcc);
+get_record_fields([{record_field, _,
{atom, _, FieldName}, {Type, _, DefaultValue}}
| Tail],
Acc) ->

0 comments on commit 80bde8b

Please sign in to comment.