]> git.lizzy.rs Git - rust.git/commit
Merge #6147
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>
Tue, 6 Oct 2020 11:36:25 +0000 (11:36 +0000)
committerGitHub <noreply@github.com>
Tue, 6 Oct 2020 11:36:25 +0000 (11:36 +0000)
commit69512dae26278f06b5ac96a7b6093abb69cdd040
treef390143fdb1feea0b6a32cef9fad7907538fb8ef
parentcb78c40b0ed1e8cf609457d63c5137022d2e1907
parentaf4ae86e2700209283333490da377767e00f5ed2
Merge #6147

6147: Do not leave braces for colons in dbg! r=matklad a=SomeoneToIgnore

Tweak remove dbg heuristics a bit to remove braces when colons (`:`) are used in the non-leaf dbg expressions.

Before:
`dbg!(Foo::foo_test()).bar()` -> `(Foo::foo_test()).bar()`

After:
`dbg!(Foo::foo_test()).bar()` -> `Foo::foo_test().bar()`

Co-authored-by: Kirill Bulatov <mail4score@gmail.com>