[llvm-bugs] [Bug 31876] New: clang-format removes space between "async" and arrow function
via llvm-bugs
llvm-bugs at lists.llvm.org
Mon Feb 6 04:13:32 PST 2017
https://llvm.org/bugs/show_bug.cgi?id=31876
Bug ID: 31876
Summary: clang-format removes space between "async" and arrow
function
Product: clang
Version: 4.0
Hardware: PC
OS: Windows NT
Status: NEW
Severity: normal
Priority: P
Component: Formatter
Assignee: unassignedclangbugs at nondot.org
Reporter: rchlodnicki at opera.com
CC: djasper at google.com, klimek at google.com,
llvm-bugs at lists.llvm.org
Classification: Unclassified
clang-format (with default config) formats this JS code:
const f1 = async () => {};
as:
const f1 = async() => {};
I would rather expect for the space after async keyword not be removed as it
looks confusing (like a function call).
Other context where async can be used is for example class members:
class Foo {
async foo() {}
}
Not really proving anything with this example...
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20170206/a9f3d787/attachment.html>
More information about the llvm-bugs
mailing list