Don't break between use keyword and single trait name
commit64167189de571b499dd77017bc5823d179f143d7
authorJake Bailey <jakebailey@fb.com>
Sat, 31 Mar 2018 02:15:19 +0000 (30 19:15 -0700)
committerHhvm Bot <hhvm-bot@users.noreply.github.com>
Sat, 31 Mar 2018 02:25:05 +0000 (30 19:25 -0700)
tree439eaa1169b3aa3136697d5944b7bc06df21ca29
parentf8aeb8c41f80cf13d01297460022d1b8d1e0726c
Don't break between use keyword and single trait name

Summary: Breaking between the use keyword and a single trait name looks inconsistent and rarely actually helps bring lines back under the length limit. This change avoids splitting after the keyword when only one trait name is listed.

Reviewed By: arxanas

Differential Revision: D7461270

fbshipit-source-id: af4ca9dbdb56aead492e3b37794c90900a1287b6
hphp/hack/src/hackfmt/hack_format.ml
hphp/hack/test/hackfmt/tests/long_single_trait_use.php [new file with mode: 0644]
hphp/hack/test/hackfmt/tests/long_single_trait_use.php.exp [new file with mode: 0644]