diff --git a/src/dfmt/formatter.d b/src/dfmt/formatter.d index 7003bfe..932955a 100644 --- a/src/dfmt/formatter.d +++ b/src/dfmt/formatter.d @@ -458,7 +458,10 @@ private: else if (currentIs(tok!"{") && config.dfmt_brace_style == BraceStyle.allman) break; else if (t == tok!"import" && !currentIs(tok!"import") - && !currentIs(tok!"}") && !(currentIs(tok!"public") + && !currentIs(tok!"}") + && !((currentIs(tok!"public") + || currentIs(tok!"private") + || currentIs(tok!"static")) && peekIs(tok!"import")) && !indents.topIsOneOf(tok!"if", tok!"debug", tok!"version")) {