Commit 5d0a43c5 authored by Bruce Momjian's avatar Bruce Momjian

Fix pgindent to not have blank line before #else in variable definition

section of a function.
parent 7690b413
......@@ -1648,14 +1648,15 @@ do
print line1;
}
}' |
# remove blank line before #endif
# remove blank line before #else and #endif
awk ' BEGIN {line1 = ""; line2 = ""; skips = 0}
{
line2 = $0;
if (skips > 0)
skips--;
if (line1 ~ /^$/ &&
line2 ~ /^#endif/)
(line2 ~ /^#else/ ||
line2 ~ /^#endif/))
{
print line2;
line2 = "";
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment