Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Formatter gets priority of objc message send expression linebreaks wrong #15721

Closed
nico opened this issue Feb 25, 2013 · 2 comments
Closed

Formatter gets priority of objc message send expression linebreaks wrong #15721

nico opened this issue Feb 25, 2013 · 2 comments
Labels
bugzilla Issues migrated from bugzilla clang-format

Comments

@nico
Copy link
Contributor

nico commented Feb 25, 2013

Bugzilla Link 15349
Resolution FIXED
Resolved on Nov 07, 2013 13:24
Version unspecified
OS All

Extended Description

trackingArea_ =
[[NSTrackingArea alloc] initWithRect:frame
options:NSTrackingMouseMoved |
NSTrackingMouseEnteredAndExited |
NSTrackingActiveInActiveApp |
NSTrackingInVisibleRect
owner:self
userInfo:nil];

becomes

trackingArea_ = [[NSTrackingArea alloc]
    initWithRect:frame
         options:NSTrackingMouseMoved | NSTrackingMouseEnteredAndExited |
    NSTrackingActiveInActiveApp | NSTrackingInVisibleRect
           owner:self
        userInfo:nil];

It should at least attempt to do

trackingArea_ = [[NSTrackingArea alloc]
    initWithRect:frame
         options:NSTrackingMouseMoved | NSTrackingMouseEnteredAndExited |
                 NSTrackingActiveInActiveApp | NSTrackingInVisibleRect
           owner:self
        userInfo:nil];
@nico
Copy link
Contributor Author

nico commented Jun 25, 2013

This became worse I think.

base::scoped_nsobject window(
[[MCPopupWindow alloc] initWithContentRect:ui::kWindowSizeDeterminedLater
styleMask:NSBorderlessWindowMask |
NSNonactivatingPanelMask
backing:NSBackingStoreBuffered
defer:YES]);

now becomes

base::scoped_nsobject window(
[[MCPopupWindow alloc] initWithContentRect:ui::kWindowSizeDeterminedLater
styleMask:NSBorderlessWindowMask |
NSNonactivatingPanelMask backing:NSBackingStoreBuffered defer:YES]);

which is pretty terrible.

Slightly related is this:

base::scoped_nsobject<NSNumber> directionValue(
    [[NSNumber alloc] initWithInteger:
        writingDirection + NSTextWritingDirectionOverride]);

becomes

base::scoped_nsobject<NSNumber> directionValue(
    [[NSNumber alloc] initWithInteger:writingDirection +
        NSTextWritingDirectionOverride]);

but the original formatting is better.

@llvmbot
Copy link
Collaborator

llvmbot commented Nov 7, 2013

Fixed in r194214.

@llvmbot llvmbot transferred this issue from llvm/llvm-bugzilla-archive Dec 4, 2021
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugzilla Issues migrated from bugzilla clang-format
Projects
None yet
Development

No branches or pull requests

2 participants