about summary refs log tree commit diff
path: root/src/test/incremental/thinlto
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2020-02-06 21:41:50 +0000
committerbors <bors@rust-lang.org>2020-02-06 21:41:50 +0000
commitb5e6d6db417a88f67e94b63463940c21bc37120b (patch)
tree87ebcb0f8d59c8a2c75ccf817ca01699de05fd52 /src/test/incremental/thinlto
parentee842df61df91f3ed3e33a23f8393c47d384ef40 (diff)
parente23881e1310f7fe02aeeecf3510a80cbac5aa808 (diff)
downloadrust-b5e6d6db417a88f67e94b63463940c21bc37120b.tar.gz
rust-b5e6d6db417a88f67e94b63463940c21bc37120b.zip
Auto merge of #5134 - flip1995:snippet_block, r=phansch
Make it possible to correctly indent snippet_block snippets

This adds a `indent_relative_to` arg to the `{snippet,expr}_block` functions. This makes it possible to keep the correct indentation of block like suggestions.

In addition, this makes the `trim_multiline` function private and adds a `indent_of` function, to get the indentation of the first line of a span.

The suggestion of `needless_continue` cannot be made auto applicable, since it would be also necessary to remove code following the linted expression. (Well, maybe it is possible, but I don't know how to do it. Expanding the suggestion span to the last expression, that should be removed didn't work)

changelog: Improve suggestions, when blocks of code are involved
Diffstat (limited to 'src/test/incremental/thinlto')
0 files changed, 0 insertions, 0 deletions