Commit Graph

406 Commits

Author SHA1 Message Date
Razvan Nitu 2beb819851
Merge pull request #535 from dlang-community/single-indent
Add single_indent option
2021-10-22 16:22:40 +03:00
Jan Jurzitza f1e57135bb
Merge pull request #534 from dlang-community/knr_brace_style 2021-10-09 09:09:50 +02:00
Eugen Wissner e8bd41c70d
Fix comment before contract
Fixes #451.
2021-09-07 14:29:45 +02:00
Sönke Ludwig b3b8ff1a43 Avoid possible null pointer access. 2021-08-16 18:09:57 +02:00
Amin Yahyaabadi 0e5615e13e
Fix the CLI help output about the `--config` option (#541) 2021-08-04 00:40:22 +03:00
belka-ew f6490b31c9
Format multiline arrays first (#538) 2021-06-16 17:23:27 +03:00
Eugen Wissner 995c21ab87 Format do like body after function attributes 2021-06-14 21:06:32 +00:00
Eugen Wissner 821b9be9e9 Fix double array indentation inside parens 2021-06-12 05:39:30 +00:00
Eugen Wissner ea36fbf58b
Add single_indent option 2021-05-18 06:36:57 +02:00
Sönke Ludwig e35bde0815 Add Kernighan & Ritchie style brace formatting.
The original K&R style behaves like BraceStyle.otbs, except for function definitions that use Allman style.
2021-04-16 13:57:21 +02:00
Eugen Wissner 1f21a97713 Don't indent associative array keys as labels 2021-03-09 11:38:33 +01:00
Eugen Wissner c4b6a7e7e3 Don't write a space after the return attribute
Fixes #521.
2021-02-27 16:06:06 +01:00
Eugen Wissner e6199aaa9b Don't output an extra newline after a comment
with keep_line_breaks=true.

Fixes #509 and #490.
2020-10-10 07:25:27 +02:00
Hackerpilot 41e8c05558 Fix #515 2020-10-07 02:19:55 -07:00
Brian Schott 7659b1ae1a
Fix Issue 508 (#511)
Fix Issue 508
merged-on-behalf-of: Brian Schott <Hackerpilot@users.noreply.github.com>
2020-10-01 08:35:20 +02:00
Eugen Wissner eab4cac12f Regenerate line break hints after newline
Fixes #486.
2020-09-04 00:14:25 +02:00
Eugen Wissner 94351246f6 Keep line break after function attributes
Fixes #504.
2020-09-02 09:09:19 +02:00
Eugen Wissner d100c40dab Print colon in AA before identifiers 2020-08-27 09:43:25 +02:00
Eugen Wissner 58b2c6ebc6 Break line on multiline strings
Fixes #476.
2020-08-10 15:25:59 +02:00
Mathis Beer b5dbb0e031 Fix issue 483: indent continuing case statements on the same level 2020-07-22 10:27:52 +02:00
Mathis Beer e4f2f20720 Fix issue 497: insert space before function/delegate in function type that returns template instantiated with parenless value argument 2020-07-20 08:04:51 +02:00
Jan Jurzitza 34810aa928 Fix stuck-while TODO (this is a do-while loop) 2020-04-03 09:19:24 +02:00
Jan Jurzitza cb1dfe091f Check for token before access, fix #474 2020-04-02 13:39:29 +02:00
Jan Jurzitza 7b955c18d1 Add hasCurrent to check if a token is available 2020-04-02 13:38:02 +02:00
Eugen Wissner ef83514541 keep_line_breaks: Compare with the token end line 2020-03-24 14:39:31 +01:00
Eugen Wissner 394da5d02a Fix break after comma, before this 2020-03-22 17:54:59 +01:00
The Dlang Bot 66faac49f1
Merge pull request #470 from dlang-community/issue-469
Fix Issue #469
merged-on-behalf-of: Brian Schott <Hackerpilot@users.noreply.github.com>
2020-03-09 10:03:20 +01:00
Hackerpilot e9034f4fec Fix return value when reading from stdin 2020-03-08 13:23:42 -07:00
Eugen Wissner 5f0d2843e6 Support disabling automatic line breaks
Support disabling automatic line breaks With --keep_line_breaks.
2020-03-07 21:14:10 +01:00
Hackerpilot 4db5ba44b2 Error out on lexer failure 2020-03-06 13:09:14 -08:00
Geod24 d38c3d96bf Replace 'body' with 'do'
The former is set to be deprecated in the next (2.091.0) DMD release.
2020-02-04 11:28:21 +09:00
Geod24 da51958770 Remove trailing whitespace 2020-02-04 11:27:58 +09:00
Eugen Wissner 27929e4cc5 Wrap the argument list of a template function
Fixes #454.
2020-01-12 22:49:16 +01:00
Eugen Wissner 0795a477f1 Put space between a comment and an identifier
Fixes #452.
2020-01-05 23:11:18 +01:00
Eugen Wissner 8f779b33bf Put a space in contract expressions
Fixes #448.
2020-01-05 20:28:56 +01:00
sobaya 06881d8654 Fix: assertion message in indent manipulation of struct initializer 2019-08-04 13:05:39 +09:00
sobaya ac8e34815f Fix: Use more readable expression 2019-08-04 13:04:39 +09:00
sobaya 05db8ae8fa Fix: indentation for wrapping in struct initializer 2019-08-01 17:43:45 +09:00
sobaya 81c607a115 Fix: extrace space after first field 2019-08-01 16:58:41 +09:00
sobaya ac61efe767 Fix: Issue 256 "named member struct initialisers" 2019-07-30 13:02:48 +09:00
Kotet 3af8edc57f Fix #361 - Unexpected empty new line if function header ends with a comment 2019-05-14 09:00:56 +09:00
Kotet f8f34ff097 Fix #426 2019-05-13 17:49:12 +09:00
Kotet 2cc1f59235 Fix #433 2019-05-13 12:13:32 +09:00
Hackerpilot b4e97d3381 Fix #436 2019-02-20 11:25:31 -08:00
Laurent Tréguier b34acc9f26 Update libdparse to v0.11.2 (#429)
Update libdparse to v0.11.2
merged-on-behalf-of: Basile-z <Basile-z@users.noreply.github.com>
2019-02-12 18:53:19 +01:00
Laurent Tréguier dae7d85c80 Fix #427 - Crash on invariant (#428)
Fix #427 - Crash on invariant
merged-on-behalf-of: Basile-z <Basile-z@users.noreply.github.com>
2019-02-11 13:55:33 +01:00
WebFreak001 7f41c8ae7f fix array item access regression 2019-01-12 12:25:46 +01:00
WebFreak001 98cd73ec80 Fix 2D (assoc) arrays & add tests
Fix #312
2019-01-11 22:06:57 +01:00
WebFreak001 eebd341343 Allow multilineAt to stop at commas 2019-01-11 22:05:41 +01:00
WebFreak001 733898e013 more informative dump function 2019-01-11 22:04:52 +01:00