This is an archive of the discontinued LLVM Phabricator instance.

clang-format: [JS] strict prop init annotation.
ClosedPublic

Authored by mprobst on Jun 11 2018, 8:46 AM.

Details

Summary

TypeScript uses the ! token for strict property initialization
assertions, as in:

class X {
  strictPropAsserted!: string;
}

Previously, clang-format would wrap between the ! and the : for
overly long lines. This patch fixes that by generally preventing the
wrap in that location.

Diff Detail

Event Timeline

mprobst updated this revision to Diff 150770.Jun 11 2018, 8:46 AM
mprobst created this revision.

fix typo in test

This revision was not accepted when it landed; it landed in state Needs Review.Jun 11 2018, 9:26 AM
This revision was automatically updated to reflect the committed changes.