Commit 1c850bf
committed
Sync leading and final newlines in source code files
This patch adds missing newlines, trims multiple redundant final
newlines into a single one, and trims redundant leading newlines.
According to POSIX, a line is a sequence of zero or more non-' <newline>'
characters plus a terminating '<newline>' character. [1] Files should
normally have at least one final newline character.
C89 [2] and later standards [3] mention a final newline:
"A source file that is not empty shall end in a new-line character,
which shall not be immediately preceded by a backslash character."
Although it is not mandatory for all files to have a final newline
fixed, a more consistent and homogeneous approach brings less of commit
differences issues and a better development experience in certain text
editors and IDEs.
[1] http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_206
[2] https://port70.net/~nsz/c/c89/c89-draft.html#2.1.1.2
[3] https://port70.net/~nsz/c/c99/n1256.html#5.1.1.21 parent a6d3e56 commit 1c850bf
File tree
476 files changed
+129
-623
lines changed- TSRM
- Zend
- tests
- return_types
- appveyor
- build
- ext
- bcmath/libbcmath
- src
- calendar
- com_dotnet
- ctype
- curl/tests
- dba
- tests
- dom/tests
- enchant
- exif
- fileinfo
- gd
- hash
- iconv
- tests
- imap/tests
- intl
- common
- dateformat
- grapheme
- tests
- uchar
- json
- ldap
- mbstring
- libmbfl
- filters
- mbfl
- nls
- tests/conv_encoding.tests
- ucgendat
- mysqli
- tests
- odbc/tests
- opcache
- tests
- openssl
- pcntl
- pcre
- pdo_dblib
- pdo_mysql
- tests
- pdo_oci
- pdo_odbc
- pdo_sqlite
- pdo
- pgsql
- tests
- phar
- phar
- tests
- cache_list/files
- files
- tar/files
- zip/files
- pspell
- readline
- reflection/tests
- session/tests
- shmop
- simplexml/tests
- skeleton
- snmp
- tests
- soap
- interop
- tests/interop
- Round2/Base
- Round3
- GroupD
- GroupE
- GroupF
- sockets
- sodium
- spl
- examples
- tests
- internal
- tests
- standard
- html_tables
- tests
- array
- class_object
- file
- windows_mb_path
- filters
- general_functions
- ini_info/scandir
- math
- misc
- streams
- sysvshm
- tidy
- tokenizer
- wddx
- xmlreader
- tests
- xmlrpc
- libxmlrpc
- xmlwriter
- xsl/tests
- 53965
- zend_test
- zip
- examples
- tests
- zlib
- tests
- main/streams
- pear
- sapi
- apache2handler
- cgi
- cli
- tests
- embed
- fpm
- fpm
- tests
- litespeed
- phpdbg
- scripts
- dev
- tests
- basic
- lang
- security
- travis/ext
- pdo_pgsql
- pgsql
- win32
- build
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
476 files changed
+129
-623
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
2 | 1 | | |
3 | 2 | | |
4 | 3 | | |
| |||
50 | 49 | | |
51 | 50 | | |
52 | 51 | | |
53 | | - | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
2 | 1 | | |
3 | 2 | | |
4 | 3 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
2 | 1 | | |
3 | 2 | | |
4 | 3 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
44 | | - | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
370 | 370 | | |
371 | 371 | | |
372 | 372 | | |
373 | | - | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
164 | 164 | | |
165 | 165 | | |
166 | 166 | | |
167 | | - | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
2 | 1 | | |
3 | 2 | | |
4 | 3 | | |
5 | | - | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
0 commit comments