http://llvm.org/bugs/show_bug.cgi?id=22647

            Bug ID: 22647
           Summary: clang-format type casts in dictionaries on wrong line
           Product: new-bugs
           Version: unspecified
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: new bugs
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected]
    Classification: Unclassified

Created attachment 13917
  --> http://llvm.org/bugs/attachment.cgi?id=13917&action=edit
The clang-format used to reproduce this issue

When defining a dictionary with keys that have a typecast the formatting is
off, concatenating the typecast to the previous line instead of having it
prefix the key.

What I would like to see:
    NSDictionary *passwordQuery = @{
        (__bridge id)kSecClass: (__bridge id)kSecClassGenericPassword,
        (__bridge id)kSecReturnData: (__bridge id)kCFBooleanTrue,
        (__bridge id)kSecReturnAttributes: (__bridge id)kCFBooleanTrue,
    };

Actual formatting:
    NSDictionary *passwordQuery = @{
        (__bridge id)kSecClass: (__bridge id)kSecClassGenericPassword,
(__bridge id)
        kSecReturnData: (__bridge id)kCFBooleanTrue, (__bridge id)
        kSecReturnAttributes: (__bridge id)kCFBooleanTrue,
    };

See attached the format file used.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs

Reply via email to