Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 8a28f50

Browse files
committed
Improve pgindent processing of comment after 'else'.
Improve comment of pg_dump Win32 link workaround.
1 parent 4e28b08 commit 8a28f50

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

src/bin/pg_dump/Makefile

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
# Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group
66
# Portions Copyright (c) 1994, Regents of the University of California
77
#
8-
# $PostgreSQL: pgsql/src/bin/pg_dump/Makefile,v 1.56 2004/10/05 19:30:23 momjian Exp $
8+
# $PostgreSQL: pgsql/src/bin/pg_dump/Makefile,v 1.57 2004/10/07 13:45:48 momjian Exp $
99
#
1010
#-------------------------------------------------------------------------
1111

@@ -22,7 +22,8 @@ OBJS= pg_backup_archiver.o pg_backup_db.o pg_backup_custom.o \
2222

2323
EXTRA_OBJS = $(top_builddir)/src/backend/parser/keywords.o
2424

25-
# not sure why MinGW needs this but it prevents a link failure
25+
# Not sure why MinGW needs this but it prevents a link failure
26+
# of duplicate definitions for pg_tolower(). 2004-10-06
2627
ifeq ($(PORTNAME), win32)
2728
EXTRA_OBJS += $(top_builddir)/src/port/exec.o
2829
endif

src/tools/pgindent/pgindent

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,10 @@ do
3838
# mark some comments for special treatment later
3939
sed 's;/\* *---;/*---X_X;g' |
4040
# workaround for indent bug with 'else' handling
41-
sed 's;\([} ]\)else\([ ]*\)\(/\*.*\)$;\1else\
42-
\2\3;g' |
41+
sed 's;\([ ]*\)else[ ]*\(/\*.*\)$;\1else\
42+
\1\2;g' |
43+
sed 's;\([ ]*\)\(}[ ]\)else[ ]*\(/\*.*\)$;\1\2else\
44+
\1\3;g' |
4345
detab -t4 -qc |
4446
# work around bug where function that defines no local variables misindents
4547
# switch() case lines and line after #else. Do not do for struct/enum.

0 commit comments

Comments
 (0)