Module Name:src
Committed By: mrg
Date: Thu Sep 4 04:06:07 UTC 2014
Modified Files:
src/usr.bin/indent: args.c indent.1 indent.c indent_globs.h io.c
Log Message:
port the -ut / -nut options from freebsd. -ut (default) enables tabs
in output, the -nut uses spaces.
To ge
Module Name:src
Committed By: rillig
Date: Sat Mar 6 20:30:07 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c io.c parse.c
Log Message:
indent: fix space-tab alignment in indent's own code
These parts are not fixed automatically by indent since they are in box
comm
Module Name:src
Committed By: rillig
Date: Sat Mar 6 21:08:08 UTC 2021
Modified Files:
src/usr.bin/indent: indent.1
Log Message:
indent.1: sort options alphabetically
To generate a diff of this commit:
cvs rdiff -u -r1.28 -r1.29 src/usr.bin/indent/indent.1
Please note
Module Name:src
Committed By: rillig
Date: Sun Mar 7 10:42:49 UTC 2021
Modified Files:
src/usr.bin/indent: args.c indent.c indent.h io.c lexi.c parse.c
pr_comment.c
Log Message:
indent: use all headers in all files
This is a prerequisite for converting the to
Module Name:src
Committed By: rillig
Date: Sun Mar 7 10:56:18 UTC 2021
Modified Files:
src/usr.bin/indent: Makefile indent.c indent.h indent_codes.h
indent_globs.h lexi.c parse.c
Log Message:
indent: for the token types, use enum instead of #define
This makes
Module Name:src
Committed By: rillig
Date: Sun Mar 7 11:32:06 UTC 2021
Modified Files:
src/usr.bin/indent: indent.h lexi.c parse.c
Log Message:
indent: in debug mode, output detailed token information
The main ingredient for understanding how indent works is the tokenize
Module Name:src
Committed By: rillig
Date: Sun Mar 7 20:30:48 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c indent_codes.h indent_globs.h lexi.c
Log Message:
indent: use named constants for the different types of keywords
This reduces the magic numbers in the cod
Module Name:src
Committed By: rillig
Date: Sun Mar 7 20:40:18 UTC 2021
Modified Files:
src/usr.bin/indent: indent_globs.h lexi.c
Log Message:
lint: move keyword 'continue' over to the other control flow keywords
No functional change since neither rw_jump nor rw_inline_or
Module Name:src
Committed By: rillig
Date: Sun Mar 7 20:47:13 UTC 2021
Modified Files:
src/usr.bin/indent: args.c io.c lexi.c
Log Message:
indent: remove redundant parentheses around return value
No functional change.
To generate a diff of this commit:
cvs rdiff -u -r1
Module Name:src
Committed By: rillig
Date: Sun Mar 7 20:52:11 UTC 2021
Modified Files:
src/usr.bin/indent: args.c indent.c
Log Message:
indent: sprinkle a few const
No functional change.
To generate a diff of this commit:
cvs rdiff -u -r1.16 -r1.17 src/usr.bin/indent/a
Module Name:src
Committed By: rillig
Date: Mon Mar 8 19:06:49 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c
Log Message:
indent: fix printing of uninitialized 'token' in debug output
To generate a diff of this commit:
cvs rdiff -u -r1.32 -r1.33 src/usr.bin/inden
Module Name:src
Committed By: rillig
Date: Mon Mar 8 19:21:41 UTC 2021
Modified Files:
src/usr.bin/indent: Makefile
Log Message:
indent: make it easy to compile indent in debug mode
To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/usr.bin/indent/Makefile
Module Name:src
Committed By: rillig
Date: Mon Mar 8 20:15:42 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c indent_globs.h lexi.c pr_comment.c
Log Message:
indent: convert big macros to functions
Each of these buffers is only modified in a single file. This make
Module Name:src
Committed By: rillig
Date: Mon Mar 8 20:20:11 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c indent_globs.h lexi.c
Log Message:
indent: inline macro for backslash
No functional change.
To generate a diff of this commit:
cvs rdiff -u -r1.34 -r1.35
Module Name:src
Committed By: rillig
Date: Mon Mar 8 21:13:34 UTC 2021
Modified Files:
src/usr.bin/indent: lexi.c
Log Message:
indent: split bsearch comparison function
It may have been a clever trick to use the same memory layout for struct
templ and a string pointer, b
Module Name:src
Committed By: rillig
Date: Mon Mar 8 22:23:58 UTC 2021
Modified Files:
src/usr.bin/indent: io.c
Log Message:
indent: always use braces in do-while loops
Having a 'while' at the beginning of a line looks as if it would start a
loop. It's confusing when it
Module Name:src
Committed By: rillig
Date: Mon Mar 8 22:26:17 UTC 2021
Modified Files:
src/usr.bin/indent: io.c
Log Message:
indent: move comment about dump_line to column 1
It looked misplaced on the right side since that area is usually
reserved for small remarks, not
Module Name:src
Committed By: rillig
Date: Mon Mar 8 22:28:31 UTC 2021
Modified Files:
src/usr.bin/indent: io.c
Log Message:
indent: remove redundant initializer in dump_line
No functional change.
To generate a diff of this commit:
cvs rdiff -u -r1.26 -r1.27 src/usr.bi
Module Name:src
Committed By: rillig
Date: Tue Mar 9 16:48:28 UTC 2021
Modified Files:
src/usr.bin/indent: args.c indent.c lexi.c parse.c pr_comment.c
Log Message:
indent: manually indent comments
It's strange that indent's own code is not formatted by indent itself,
whi
Module Name:src
Committed By: rillig
Date: Tue Mar 9 18:21:01 UTC 2021
Modified Files:
src/usr.bin/indent: parse.c
Log Message:
indent: extract reduce_stmt from reduce
This refactoring reduces the indentation of the code, as well as
removing any ambiguity as to which 'sw
Module Name:src
Committed By: rillig
Date: Tue Mar 9 18:28:10 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c indent_codes.h lexi.c
Log Message:
indent: rename a few tokens to be more obvious
For casual readers it is not obvious whether the 'sp' meant 'special' or
Module Name:src
Committed By: rillig
Date: Tue Mar 9 19:14:39 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c indent_codes.h lexi.c parse.c
Log Message:
indent: make token names more precise
The previous 'casestmt' was wrong since a case label is not a statement
at
Module Name:src
Committed By: rillig
Date: Tue Mar 9 19:23:08 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c indent_codes.h lexi.c
Log Message:
indent: rename a few more token types
The previous names were either too short or ambiguous.
No functional change.
To
Module Name:src
Committed By: rillig
Date: Tue Mar 9 19:32:41 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c
Log Message:
indent: extract capsicum code out of the main function
No functional change.
To generate a diff of this commit:
cvs rdiff -u -r1.39 -r1.40 s
Module Name:src
Committed By: rillig
Date: Tue Mar 9 19:46:28 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c
Log Message:
indent: extract search_brace from main
No functional change.
To generate a diff of this commit:
cvs rdiff -u -r1.40 -r1.41 src/usr.bin/inden
Module Name:src
Committed By: rillig
Date: Thu Mar 11 21:47:36 UTC 2021
Modified Files:
src/usr.bin/indent: lexi.c
Log Message:
indent: merge duplicate code for reading from the input buffer
No functional change.
To generate a diff of this commit:
cvs rdiff -u -r1.31 -r
Module Name:src
Committed By: rillig
Date: Thu Mar 11 22:15:44 UTC 2021
Modified Files:
src/usr.bin/indent: lexi.c pr_comment.c
Log Message:
indent: use consistent array indexing
No functional change.
To generate a diff of this commit:
cvs rdiff -u -r1.32 -r1.33 src/usr
Module Name:src
Committed By: rillig
Date: Thu Mar 11 22:28:30 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c lexi.c pr_comment.c
Log Message:
indent: remove redundant cast after allocation functions
No functional change.
To generate a diff of this commit:
cvs rd
Module Name:src
Committed By: rillig
Date: Thu Mar 11 22:32:06 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c lexi.c pr_comment.c
Log Message:
indent: reduce indentation of check_size functions
No functional change.
To generate a diff of this commit:
cvs rdiff -u
Module Name:src
Committed By: rillig
Date: Fri Mar 12 00:15:34 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c
Log Message:
indent: manually fix indentation
No functional change.
To generate a diff of this commit:
cvs rdiff -u -r1.43 -r1.44 src/usr.bin/indent/inde
Module Name:src
Committed By: rillig
Date: Fri Mar 12 17:46:49 UTC 2021
Modified Files:
src/usr.bin/indent: lexi.c
Log Message:
indent: move code for tokenizing numbers further up
Having it directly below the table makes it easier understandable.
I also tried to omit thi
Module Name:src
Committed By: rillig
Date: Fri Mar 12 18:11:50 UTC 2021
Modified Files:
src/usr.bin/indent: lexi.c
Log Message:
indent: fix misleading indentation in indent's own code
No functional change.
To generate a diff of this commit:
cvs rdiff -u -r1.36 -r1.37 sr
Module Name:src
Committed By: rillig
Date: Fri Mar 12 19:11:29 UTC 2021
Modified Files:
src/usr.bin/indent: Makefile io.c
Log Message:
indent: add helper functions for doing the actual output
This allows to add debug logging to these few functions instead of all
other pla
Module Name:src
Committed By: rillig
Date: Fri Mar 12 19:14:18 UTC 2021
Modified Files:
src/usr.bin/indent: io.c
Log Message:
indent: make output_string inline
GCC 9.3.0 didn't notice that the argument to this function is always a
string literal, which makes it worthwhile
Module Name:src
Committed By: rillig
Date: Fri Mar 12 23:10:18 UTC 2021
Modified Files:
src/usr.bin/indent: args.c indent.c io.c lexi.c parse.c pr_comment.c
Log Message:
indent: use consistent indentation for 'else'
Half of the code used -ce, the other half the opposite -
Module Name:src
Committed By: rillig
Date: Fri Mar 12 23:16:00 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c indent.h io.c pr_comment.c
Log Message:
indent: replace 'target' with 'indent' in function names
The word 'target' was not as specific as possible.
No fun
Module Name:src
Committed By: rillig
Date: Fri Mar 12 23:27:41 UTC 2021
Modified Files:
src/usr.bin/indent: indent.h io.c
Log Message:
indent: add 'const', rename variables, reorder formula for tab width
Column counting starts at 1. This 1 should rather be at the beginni
Module Name:src
Committed By: rillig
Date: Sat Mar 13 00:03:30 UTC 2021
Modified Files:
src/usr.bin/indent: io.c
Log Message:
indent: clean up verbose documentation comments from the 1970s
Since C90, there is no need to repeat the type of the function
parameters.
In the
Module Name:src
Committed By: rillig
Date: Sat Mar 13 00:26:56 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c indent.h io.c pr_comment.c
Log Message:
indent: replace pad_output with output_indent
Calculating the indentation is simpler than calculating the column,
s
Module Name:src
Committed By: rillig
Date: Sat Mar 13 09:06:12 UTC 2021
Modified Files:
src/usr.bin/indent: io.c
Log Message:
indent: remove strange debugging code that went in the output file
Whenever the code to be output contained the magic byte 0x80, instead of
writin
Module Name:src
Committed By: rillig
Date: Sat Mar 13 09:21:57 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c indent.h io.c lexi.c
Log Message:
indent: add debug logging for actually writing to the output file
Together with the results of the tokenizer and the 4 bu
Module Name:src
Committed By: rillig
Date: Sat Mar 13 09:48:04 UTC 2021
Modified Files:
src/usr.bin/indent: io.c
Log Message:
indent: manually fix indentation in indent's own source code
To generate a diff of this commit:
cvs rdiff -u -r1.36 -r1.37 src/usr.bin/indent/io.
Module Name:src
Committed By: rillig
Date: Sat Mar 13 09:54:12 UTC 2021
Modified Files:
src/usr.bin/indent: indent.h io.c pr_comment.c
Log Message:
indent: replace compute_label_column with compute_label_indent
Using the invariant 'column == 1 + indent'. This removes sev
Module Name:src
Committed By: rillig
Date: Sat Mar 13 10:06:47 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c indent.h io.c pr_comment.c
Log Message:
indent: replace compute_code_column with compute_code_indent
The goal is to only ever be concerned about the _inden
Module Name:src
Committed By: rillig
Date: Sat Mar 13 10:20:54 UTC 2021
Modified Files:
src/usr.bin/indent: indent.h io.c
Log Message:
indent: replace column computation with indentation computation
No functional change.
To generate a diff of this commit:
cvs rdiff -u -
Module Name:src
Committed By: rillig
Date: Sat Mar 13 10:32:25 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c indent.h io.c pr_comment.c
Log Message:
indent: inline calls to count_spaces and count_spaces_until
These two functions operated on column numbers instead
Module Name:src
Committed By: rillig
Date: Sat Mar 13 10:47:59 UTC 2021
Modified Files:
src/usr.bin/indent: pr_comment.c
Log Message:
indent: document undefined behavior in processing of comments
No functional change.
To generate a diff of this commit:
cvs rdiff -u -r1.
Module Name:src
Committed By: rillig
Date: Sat Mar 13 11:19:43 UTC 2021
Modified Files:
src/usr.bin/indent: args.c indent.c indent_globs.h io.c pr_comment.c
Log Message:
indent: fix confusing variable names
The word 'col' should only be used for the 1-based column number.
Module Name:src
Committed By: rillig
Date: Sat Mar 13 11:27:01 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c lexi.c pr_comment.c
Log Message:
indent: remove redundant parentheses
No functional change.
To generate a diff of this commit:
cvs rdiff -u -r1.51 -r1.52
Module Name:src
Committed By: rillig
Date: Sat Mar 13 11:47:22 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c
Log Message:
indent: split 'main' into manageable parts
Since several years (maybe even decades) compilers know how to inline
static functions that are onl
Module Name:src
Committed By: rillig
Date: Sat Mar 13 12:52:24 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c
Log Message:
indent: split 'main_loop' into several functions
No functional change.
To generate a diff of this commit:
cvs rdiff -u -r1.53 -r1.54 src/usr
Module Name:src
Committed By: rillig
Date: Sat Mar 13 13:25:23 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c indent.h indent_globs.h pr_comment.c
Log Message:
indent: rename pr_comment to process_comment, clean up documentation
No functional change.
To generate
Module Name:src
Committed By: rillig
Date: Sat Mar 13 13:51:08 UTC 2021
Modified Files:
src/usr.bin/indent: args.c indent.c indent_globs.h io.c pr_comment.c
Log Message:
indent: distinguish between 'column' and 'indentation'
column == 1 + indentation.
In addition, indent
Module Name:src
Committed By: rillig
Date: Sat Mar 13 13:54:01 UTC 2021
Modified Files:
src/usr.bin/indent: io.c
Log Message:
indent: in dump_line, reduce scope of local variable
This allows the variable 'target' in the lower half of the function to
get a more specific na
Module Name:src
Committed By: rillig
Date: Sat Mar 13 13:55:42 UTC 2021
Modified Files:
src/usr.bin/indent: io.c
Log Message:
indent: rename local variable in dump_line
This clarifies that the variable names a column, not an indentation.
To generate a diff of this commi
Module Name:src
Committed By: rillig
Date: Sat Mar 13 18:11:31 UTC 2021
Modified Files:
src/usr.bin/indent: pr_comment.c
Log Message:
indent: remove the '+ 1' from right margin calculation in comment
No functional change.
To generate a diff of this commit:
cvs rdiff -u
Module Name:src
Committed By: rillig
Date: Sat Mar 13 18:24:56 UTC 2021
Modified Files:
src/usr.bin/indent: io.c
Log Message:
indent: align comments in indent's own code
No functional change.
To generate a diff of this commit:
cvs rdiff -u -r1.45 -r1.46 src/usr.bin/inde
Module Name:src
Committed By: rillig
Date: Sat Mar 13 18:46:39 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c io.c
Log Message:
indent: add debug logging for switching the input buffer
No functional change outside debug mode.
To generate a diff of this commit:
cv
Module Name:src
Committed By: rillig
Date: Sat Mar 13 23:36:10 UTC 2021
Modified Files:
src/usr.bin/indent: indent_globs.h
Log Message:
indent: fix documentation of parser_state.paren_indents
The column position is not the same as the indentation (off-by-one).
To genera
Module Name:src
Committed By: rillig
Date: Sat Mar 13 23:42:23 UTC 2021
Modified Files:
src/usr.bin/indent: indent.h
Log Message:
indent: remove disabled duplicate RCS ID from header
By convention, headers don't record their RCS ID.
To generate a diff of this commit:
cv
Module Name:src
Committed By: rillig
Date: Sun Mar 14 00:22:16 UTC 2021
Modified Files:
src/usr.bin/indent: Makefile args.c indent.c io.c lexi.c pr_comment.c
Log Message:
indent: fix lint warnings
No functional change.
To generate a diff of this commit:
cvs rdiff -u -r1
Module Name:src
Committed By: rillig
Date: Sun Mar 14 00:33:25 UTC 2021
Modified Files:
src/usr.bin/indent: indent.h
Log Message:
indent: give indent a try at formatting its own code
Formatting indent.h required the following manual corrections
afterwards:
The first tab
Module Name:src
Committed By: rillig
Date: Sun Mar 14 01:44:37 UTC 2021
Modified Files:
src/usr.bin/indent: io.c
Log Message:
indent: make compute_code_indent more readable
The '?:' operator computing the factor was too hard to read. When
quickly scanning the code, the 1
Module Name:src
Committed By: rillig
Date: Sun Mar 14 04:42:17 UTC 2021
Modified Files:
src/usr.bin/indent: pr_comment.c
Log Message:
indent: clean up target column computation in process_comment
No functional change.
To generate a diff of this commit:
cvs rdiff -u -r1.
Module Name:src
Committed By: rillig
Date: Sun Mar 14 04:52:10 UTC 2021
Modified Files:
src/usr.bin/indent: pr_comment.c
Log Message:
indent: remove trailing whitespace
To generate a diff of this commit:
cvs rdiff -u -r1.33 -r1.34 src/usr.bin/indent/pr_comment.c
Please
Module Name:src
Committed By: rillig
Date: Sun Mar 14 05:26:42 UTC 2021
Modified Files:
src/usr.bin/indent: pr_comment.c
Log Message:
indent: clean up check_size_comment
The additional parameter last_bl_ptr was only necessary because the last
blank was stored as a pointer
Module Name:src
Committed By: rillig
Date: Fri Mar 26 22:02:00 UTC 2021
Modified Files:
src/usr.bin/indent: indent.c
Log Message:
indent: fix Clang build everywhere but on amd64
No idea why Clang didn't complain about this on amd64, only on all other
platforms.
To gener
Module Name:src
Committed By: rillig
Date: Fri Mar 26 22:27:43 UTC 2021
Modified Files:
src/usr.bin/indent: Makefile
Log Message:
indent: remove workaround for array initialization bug in lint
The bug has been fixed in init.c 1.133 from 2021-03-25.
To generate a diff of
Module Name:src
Committed By: rillig
Date: Fri Mar 26 22:33:54 UTC 2021
Modified Files:
src/usr.bin/indent: README
Log Message:
indent: don't claim that indent is "the nicest C pretty printer around"
That statement may have been true in 1993, but definitely is not true
an
Module Name:src
Committed By: ginsbach
Date: Mon Feb 22 19:04:18 UTC 2016
Modified Files:
src/usr.bin/indent: args.c indent.c io.c
Log Message:
Use errx(3).
To generate a diff of this commit:
cvs rdiff -u -r1.11 -r1.12 src/usr.bin/indent/args.c
cvs rdiff -u -r1.19 -r1.20
Module Name:src
Committed By: ginsbach
Date: Mon Feb 22 21:20:29 UTC 2016
Modified Files:
src/usr.bin/indent: args.c
Log Message:
Stray '\n' in errx(3) format.
To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/usr.bin/indent/args.c
Please note that diffs
Module Name:src
Committed By: ginsbach
Date: Mon Feb 22 22:01:48 UTC 2016
Modified Files:
src/usr.bin/indent: indent.c
Log Message:
Use warnx(3).
To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/usr.bin/indent/indent.c
Please note that diffs are not pub
Module Name:src
Committed By: ginsbach
Date: Wed Feb 24 17:13:48 UTC 2016
Modified Files:
src/usr.bin/indent: indent.1
Log Message:
Add the [n]ei and [n]eei options to the synopsis; already documented in
description.
To generate a diff of this commit:
cvs rdiff -u -r1.23
Module Name:src
Committed By: ginsbach
Date: Wed Feb 24 17:38:15 UTC 2016
Modified Files:
src/usr.bin/indent: indent.1
Log Message:
Remove double space before [.,:] in macro arguments.
To generate a diff of this commit:
cvs rdiff -u -r1.24 -r1.25 src/usr.bin/indent/inden
Module Name:src
Committed By: ginsbach
Date: Thu Feb 25 13:23:27 UTC 2016
Modified Files:
src/usr.bin/indent: indent.c io.c pr_comment.c
Log Message:
Fix obvious contraction spelling mistakes by adding missing apostrophes.
To generate a diff of this commit:
cvs rdiff -u
Module Name:src
Committed By: wiz
Date: Thu Feb 25 14:55:56 UTC 2016
Modified Files:
src/usr.bin/indent: indent.1
Log Message:
Remove trailing whitespace.
To generate a diff of this commit:
cvs rdiff -u -r1.25 -r1.26 src/usr.bin/indent/indent.1
Please note that diffs ar
Module Name:src
Committed By: dholland
Date: Sun Jun 5 18:35:32 UTC 2016
Modified Files:
src/usr.bin/indent: lexi.c
Log Message:
Fix CSRG-era typo: typedef, not typdef. Spotted by Piotr Stefaniak.
To generate a diff of this commit:
cvs rdiff -u -r1.13 -r1.14 src/usr.bin
Module Name:src
Committed By: wiz
Date: Wed Jan 12 06:17:52 UTC 2011
Modified Files:
src/usr.bin/indent: indent.1
Log Message:
Spell out parenthesis. From Ryo HAYASAKA in PR 44372.
To generate a diff of this commit:
cvs rdiff -u -r1.19 -r1.20 src/usr.bin/indent/indent.1
Module Name:src
Committed By: wiz
Date: Thu Apr 4 22:02:06 UTC 2019
Modified Files:
src/usr.bin/indent: indent.1
Log Message:
New sentence, new line. Whitespace fixes.
To generate a diff of this commit:
cvs rdiff -u -r1.27 -r1.28 src/usr.bin/indent/indent.1
Please not
Module Name:src
Committed By: joerg
Date: Thu Apr 23 00:17:34 UTC 2020
Modified Files:
src/usr.bin/indent: indent.c indent_globs.h
Log Message:
Avoid common symbol declarations
To generate a diff of this commit:
cvs rdiff -u -r1.26 -r1.27 src/usr.bin/indent/indent.c
cvs
80 matches
Mail list logo