Seiichi Uchida
27167cbbaa
Format code block in comment
...
Closes #554 .
Closes #1695 .
2017-12-24 23:56:51 +09:00
Seiichi Uchida
ccc487ade7
Do not put comment's line start and closer on the same line
2017-12-17 15:25:24 +09:00
Seiichi Uchida
81eb88c4c0
Respect leading whitespace in original comment when wrapping comment
2017-12-17 15:24:49 +09:00
Seiichi Uchida
516f15aba1
Cargo clippy
2017-12-12 13:48:12 +09:00
Nick Cameron
644b60ad85
Merge pull request #2257 from topecongiro/error-on-line-overflow-strings
...
Add error_on_line_overflow_strings config option
2017-12-11 16:41:15 +13:00
Seiichi Uchida
6c3de706ae
Make RichChar public
2017-12-11 11:48:17 +09:00
Seiichi Uchida
d1e5d7866b
Make CharClasses and FullCodeCharKind public
2017-12-11 11:47:19 +09:00
Seiichi Uchida
5faf31bb32
Trim a trailing whitespace on empty line inside code block comment
2017-12-11 11:37:13 +09:00
Seiichi Uchida
3ebe054362
Replace into() on &str with to_owned()
2017-12-08 13:07:42 +09:00
Seiichi Uchida
7c4a84751f
Convert '&str' into 'String' whenever necessary
2017-12-07 13:57:52 +09:00
Nick Cameron
b07e4339f0
Merge pull request #2221 from topecongiro/rfc/blank-lines
...
Keep vertical spaces between items or statements within range
2017-12-06 15:52:19 +13:00
Seiichi Uchida
228578b9c7
Add count_newlines() utility function
2017-12-05 15:17:40 +09:00
topecongiro
16184d3e16
Cargo fmt and update a test
2017-12-03 11:34:18 +09:00
Seiichi Uchida
b9126fac82
Do not format fenced code blocks in comment
2017-12-02 23:01:50 +09:00
Seiichi Uchida
89f27764ed
Cargo fmt and update tests
2017-12-02 17:45:39 +09:00
topecongiro
8b53d7806c
Cargo fmt
2017-11-29 17:37:51 +09:00
topecongiro
34c2499029
Cargo fmt
2017-11-16 17:43:06 +09:00
topecongiro
4e1a75a429
Collapse if-else
2017-11-06 13:52:25 +09:00
topecongiro
b17de6228f
Cargo fmt
2017-11-02 21:45:00 +09:00
Nick Cameron
809e06ee32
Merge pull request #2102 from topecongiro/soft-wrapping-comments
...
Soft wrapping for comments
2017-11-02 15:15:38 +13:00
Martin Lindhe
f930a16b8d
fix some typos
2017-11-01 07:33:55 +01:00
topecongiro
471e9110f5
Add ftp and file protocols
2017-11-01 12:35:32 +09:00
topecongiro
dae76d21ff
Implement soft wrapping for comments
2017-10-31 15:07:58 +09:00
topecongiro
38399875b8
Add has_url()
2017-10-31 15:07:19 +09:00
Nick Cameron
802df67c2f
Merge pull request #2035 from topecongiro/deprecate-try_opt!
...
Replace `try_opt!` macro with a `?` operator
2017-10-05 20:45:52 +08:00
topecongiro
fe69dde96b
Replace 'try_opt!' macro with a '?' operator
2017-10-05 20:50:19 +09:00
topecongiro
106625bc5c
Remove trailing whitespaces in macro def
2017-10-05 16:17:59 +09:00
topecongiro
9e963b87fc
Add InString field to FullCodeCharKind
2017-10-05 16:17:04 +09:00
Seiichi Uchida
df7d2be562
Move Indent and Shape to shape.rs from lib.rs
2017-09-19 10:04:35 +09:00
Seiichi Uchida
18cd19673d
Remove wrap_str() from recover_comment_removed()
...
since we will be using the original snippet no matter what.
2017-09-18 23:30:59 +09:00
Seiichi Uchida
20aecb3d98
Run recover_comment_removed() only if the text changed after format
2017-09-18 22:56:29 +09:00
topecongiro
f51261e93e
Cargo fmt
2017-09-15 12:10:58 +09:00
Seiichi Uchida
4b79055a15
Apply refactoring from cargo clippy
2017-08-31 12:49:12 +09:00
topecongiro
6bbc6b54de
Refactor - remove duplicates
...
replacing some functions with recover_missing_comments() and
rewrite_missing_comments().
2017-08-28 00:13:42 +09:00
topecongiro
66b1642624
Add recover_missing_comment_in_span() and rewrite_missing_comment()
2017-08-28 00:11:25 +09:00
topecongiro
0af19985fc
Generalize combine_attr_and_expr
2017-08-11 17:52:13 +09:00
topecongiro
38614e7af1
Format source codes and update tests
2017-07-26 17:43:17 +09:00
Seiichi Uchida
de403f4f65
Use offset_left instead of shrink_left
2017-07-20 00:41:36 +09:00
topecongiro
6fd291981e
Sort imports in alphabetical and consistent order
2017-07-13 18:42:14 +09:00
topecongiro
e3310a6a18
Format source codes
2017-07-11 21:53:10 +09:00
Seiichi Uchida
bc63d69c3f
Format source codes
2017-07-10 02:24:59 +09:00
topecongiro
54233acc8e
Format source codes
2017-06-17 16:56:54 +09:00
topecongiro
b048fe6b35
Format source codes
2017-06-17 15:26:59 +09:00
topecongiro
208ff15954
Format source codes
2017-06-16 08:49:49 +09:00
topecongiro
b8f11a4e3c
Format source codes
2017-06-14 20:39:07 +09:00
Nick Cameron
1f512948a0
Reformat source code using new defaults
2017-06-13 14:41:49 +12:00
topecongiro
924a9b5cb6
Allow longer custom comment
2017-05-30 08:46:25 +09:00
topecongiro
bcebe9e7de
Use different style when rewriting comment with different opener
2017-05-29 11:28:48 +09:00
topecongiro
ec33121aaf
Format source codes
2017-05-23 22:13:29 +09:00
Michael Killough
222bac1397
Provide config.set().item(value)
API.
...
This API isn't fantastic, but it's the best I can come up with without
something like `concat_idents!()`. There are relatively few places where
config is set, to hopefully the ugliness isn't disastrous.
Change previous occurences of `config.item = value` to this new API,
rather than using `config.override_value()`. Undo the changes to
`override_value()`, as it's no longer important to propogate the error
to the caller. Add a test for the new interface.
2017-05-18 11:42:32 +07:00