-
Notifications
You must be signed in to change notification settings - Fork 64
Description
Sometimes I need to nest macro directives, and when I do so, it's nice to indent them as one would do with code generally - just to keep it readable - however, erlfmt seems to want to remove all indentation, for example:
-ifdef(FOO).
-ifndef(BAR).
-define(BAZ, true).
-endif.
-endif.
--[apply erlfmt]-->
-ifdef(FOO).
-ifndef(BAR).
-define(BAZ, true).
-endif.
-endif.
I don't think there's any mention of this in the style guide. As far as I can see, the macro-related stuff covers various topics, but doesn't consider flow control for macro definitions, and treats it as I would treat a list of several -defines or something. Also, I am not a frequent user of erlfmt, so maybe I am doing something wrong, making this a support request rather than a feature request.
I know nesting macro directives like this is probably Not Good™, but I'd prefer not to compound that by needing to have them flattened out.
Thanks!