[Midnightbsd-cvs] src [11528] trunk/usr.bin/indent: fix a few issues
laffer1 at midnightbsd.org
laffer1 at midnightbsd.org
Sat Jul 7 16:28:36 EDT 2018
Revision: 11528
http://svnweb.midnightbsd.org/src/?rev=11528
Author: laffer1
Date: 2018-07-07 16:28:35 -0400 (Sat, 07 Jul 2018)
Log Message:
-----------
fix a few issues
Modified Paths:
--------------
trunk/usr.bin/indent/Makefile
trunk/usr.bin/indent/args.c
trunk/usr.bin/indent/indent.1
trunk/usr.bin/indent/indent.c
trunk/usr.bin/indent/indent.h
trunk/usr.bin/indent/indent_codes.h
trunk/usr.bin/indent/indent_globs.h
trunk/usr.bin/indent/io.c
trunk/usr.bin/indent/lexi.c
Property Changed:
----------------
trunk/usr.bin/indent/indent.1
Modified: trunk/usr.bin/indent/Makefile
===================================================================
--- trunk/usr.bin/indent/Makefile 2018-07-07 20:27:48 UTC (rev 11527)
+++ trunk/usr.bin/indent/Makefile 2018-07-07 20:28:35 UTC (rev 11528)
@@ -1,6 +1,10 @@
+# $MidnightBSD$
# @(#)Makefile 8.1 (Berkeley) 6/6/93
+# $FreeBSD: stable/10/usr.bin/indent/Makefile 249657 2013-04-19 19:45:00Z ed $
PROG= indent
SRCS= indent.c io.c lexi.c parse.c pr_comment.c args.c
+NO_WMISSING_VARIABLE_DECLARATIONS=
+
.include <bsd.prog.mk>
Modified: trunk/usr.bin/indent/args.c
===================================================================
--- trunk/usr.bin/indent/args.c 2018-07-07 20:27:48 UTC (rev 11527)
+++ trunk/usr.bin/indent/args.c 2018-07-07 20:28:35 UTC (rev 11528)
@@ -1,3 +1,4 @@
+/* $MidnightBSD$ */
/*
* Copyright (c) 1985 Sun Microsystems, Inc.
* Copyright (c) 1980, 1993
@@ -40,7 +41,7 @@
#endif
#include <sys/cdefs.h>
-__MBSDID("$MidnightBSD$");
+__FBSDID("$FreeBSD: stable/10/usr.bin/indent/args.c 205989 2010-03-31 17:05:30Z avg $");
/*
* Argument scanning and profile reading code. Default parameters are set
Modified: trunk/usr.bin/indent/indent.1
===================================================================
--- trunk/usr.bin/indent/indent.1 2018-07-07 20:27:48 UTC (rev 11527)
+++ trunk/usr.bin/indent/indent.1 2018-07-07 20:28:35 UTC (rev 11528)
@@ -1,3 +1,4 @@
+.\" $MidnightBSD$
.\" Copyright (c) 1980, 1990, 1993
.\" The Regents of the University of California. All rights reserved.
.\" Copyright (c) 1976 Board of Trustees of the University of Illinois.
@@ -32,7 +33,7 @@
.\" SUCH DAMAGE.
.\"
.\" @(#)indent.1 8.1 (Berkeley) 7/1/93
-.\" $MidnightBSD$
+.\" $FreeBSD: stable/10/usr.bin/indent/indent.1 293290 2016-01-07 00:40:51Z bdrewery $
.\"
.Dd March 3, 2012
.Dt INDENT 1
@@ -488,7 +489,6 @@
utility fits as many words (separated by blanks, tabs, or newlines) on a
line as possible.
Blank lines break paragraphs.
-.Pp
.Ss Comment indentation
If a comment is on a line with code it is started in the `comment column',
which is set by the
@@ -504,7 +504,6 @@
If the code on a line extends past the comment
column, the comment starts further to the right, and the right margin may be
automatically extended in extreme cases.
-.Pp
.Ss Preprocessor lines
In general,
.Nm
@@ -519,7 +518,6 @@
.Nm
attempts to correctly
compensate for the syntactic peculiarities introduced.
-.Pp
.Ss C syntax
The
.Nm
@@ -526,7 +524,7 @@
utility understands a substantial amount about the syntax of C, but it
has a `forgiving' parser.
It attempts to cope with the usual sorts of
-incomplete and misformed syntax.
+incomplete and malformed syntax.
In particular, the use of macros like:
.Pp
.Dl #define forever for(;;)
Property changes on: trunk/usr.bin/indent/indent.1
___________________________________________________________________
Added: svn:keywords
## -0,0 +1 ##
+MidnightBSD=%H
\ No newline at end of property
Modified: trunk/usr.bin/indent/indent.c
===================================================================
--- trunk/usr.bin/indent/indent.c 2018-07-07 20:27:48 UTC (rev 11527)
+++ trunk/usr.bin/indent/indent.c 2018-07-07 20:28:35 UTC (rev 11528)
@@ -1,3 +1,4 @@
+/* $MidnightBSD$ */
/*
* Copyright (c) 1985 Sun Microsystems, Inc.
* Copyright (c) 1976 Board of Trustees of the University of Illinois.
@@ -48,7 +49,7 @@
#endif
#include <sys/cdefs.h>
-__MBSDID("$MidnightBSD$");
+__FBSDID("$FreeBSD: stable/10/usr.bin/indent/indent.c 228992 2011-12-30 11:02:40Z uqs $");
#include <sys/param.h>
#include <err.h>
@@ -326,7 +327,7 @@
case lbrace: /* this is a brace that starts the compound
* stmt */
- if (sc_end == 0) { /* ignore buffering if a comment wasnt
+ if (sc_end == 0) { /* ignore buffering if a comment wasn't
* stored up */
ps.search_brace = false;
goto check_type;
@@ -384,7 +385,7 @@
&& e_code != s_code && e_code[-1] == '}'))
force_nl = false;
- if (sc_end == 0) { /* ignore buffering if comment wasnt
+ if (sc_end == 0) { /* ignore buffering if comment wasn't
* saved up */
ps.search_brace = false;
goto check_type;
@@ -794,8 +795,8 @@
/* ? dec_ind = 0; */
}
else {
- ps.decl_on_line = false; /* we cant be in the middle of
- * a declaration, so dont do
+ ps.decl_on_line = false; /* we can't be in the middle of
+ * a declaration, so don't do
* special indentation of
* comments */
if (blanklines_after_declarations_at_proctop
Modified: trunk/usr.bin/indent/indent.h
===================================================================
--- trunk/usr.bin/indent/indent.h 2018-07-07 20:27:48 UTC (rev 11527)
+++ trunk/usr.bin/indent/indent.h 2018-07-07 20:28:35 UTC (rev 11528)
@@ -1,3 +1,4 @@
+/* $MidnightBSD$ */
/*
* Copyright (c) 2001 Jens Schweikhardt
* All rights reserved.
@@ -25,7 +26,7 @@
*/
#if 0
-__MBSDID("$MidnightBSD$");
+__FBSDID("$FreeBSD: stable/10/usr.bin/indent/indent.h 93440 2002-03-30 17:10:20Z dwmalone $");
#endif
void addkey(char *, int);
Modified: trunk/usr.bin/indent/indent_codes.h
===================================================================
--- trunk/usr.bin/indent/indent_codes.h 2018-07-07 20:27:48 UTC (rev 11527)
+++ trunk/usr.bin/indent/indent_codes.h 2018-07-07 20:28:35 UTC (rev 11528)
@@ -1,3 +1,4 @@
+/* $MidnightBSD$ */
/*
* Copyright (c) 1985 Sun Microsystems, Inc.
* Copyright (c) 1980, 1993
@@ -33,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)indent_codes.h 8.1 (Berkeley) 6/6/93
- * $MidnightBSD$
+ * $FreeBSD: stable/10/usr.bin/indent/indent_codes.h 69796 2000-12-09 09:52:52Z obrien $
*/
#define newline 1
Modified: trunk/usr.bin/indent/indent_globs.h
===================================================================
--- trunk/usr.bin/indent/indent_globs.h 2018-07-07 20:27:48 UTC (rev 11527)
+++ trunk/usr.bin/indent/indent_globs.h 2018-07-07 20:28:35 UTC (rev 11528)
@@ -1,3 +1,4 @@
+/* $MidnightBSD$ */
/*
* Copyright (c) 1985 Sun Microsystems, Inc.
* Copyright (c) 1980, 1993
@@ -33,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)indent_globs.h 8.1 (Berkeley) 6/6/93
- * $MidnightBSD$
+ * $FreeBSD: stable/10/usr.bin/indent/indent_globs.h 244578 2012-12-22 04:11:59Z andrew $
*/
#define BACKSLASH '\\'
@@ -213,7 +214,7 @@
char font[4];
char size;
int allcaps:1;
-};
+} __aligned(sizeof(int));
char *chfont(struct fstate *, struct fstate *, char *);
struct fstate
Modified: trunk/usr.bin/indent/io.c
===================================================================
--- trunk/usr.bin/indent/io.c 2018-07-07 20:27:48 UTC (rev 11527)
+++ trunk/usr.bin/indent/io.c 2018-07-07 20:28:35 UTC (rev 11528)
@@ -1,3 +1,4 @@
+/* $MidnightBSD$ */
/*
* Copyright (c) 1985 Sun Microsystems, Inc.
* Copyright (c) 1980, 1993
@@ -40,7 +41,7 @@
#endif
#include <sys/cdefs.h>
-__MBSDID("$MidnightBSD$");
+__FBSDID("$FreeBSD: stable/10/usr.bin/indent/io.c 228992 2011-12-30 11:02:40Z uqs $");
#include <ctype.h>
#include <err.h>
@@ -232,7 +233,7 @@
target = ((target - 1) & ~7) + 9, com_st++;
else
target = 1;
- if (cur_col > target) { /* if comment cant fit on this line,
+ if (cur_col > target) { /* if comment can't fit on this line,
* put it on next line */
putc('\n', output);
cur_col = 1;
Modified: trunk/usr.bin/indent/lexi.c
===================================================================
--- trunk/usr.bin/indent/lexi.c 2018-07-07 20:27:48 UTC (rev 11527)
+++ trunk/usr.bin/indent/lexi.c 2018-07-07 20:28:35 UTC (rev 11528)
@@ -1,3 +1,4 @@
+/* $MidnightBSD$ */
/*
* Copyright (c) 1985 Sun Microsystems, Inc.
* Copyright (c) 1980, 1993
@@ -39,7 +40,7 @@
#endif /* not lint */
#endif
#include <sys/cdefs.h>
-__MBSDID("$MidnightBSD$");
+__FBSDID("$FreeBSD: stable/10/usr.bin/indent/lexi.c 301743 2016-06-09 16:29:19Z pfg $");
/*
* Here we have the token scanner for indent. It scans off one token and puts
@@ -79,7 +80,7 @@
{"double", 4},
{"long", 4},
{"short", 4},
- {"typdef", 4},
+ {"typedef", 4},
{"unsigned", 4},
{"register", 4},
{"static", 4},
More information about the Midnightbsd-cvs
mailing list