This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 186457 - Overridden property's on replace handler not formatted correctly
Summary: Overridden property's on replace handler not formatted correctly
Status: VERIFIED DUPLICATE of bug 184262
Alias: None
Product: javafx
Classification: Unclassified
Component: Editor (show other bugs)
Version: 6.x
Hardware: PC Mac OS X
: P3 normal (vote)
Assignee: Anton Chechel
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-05-20 20:51 UTC by Torbjorn Norbye
Modified: 2010-06-17 09:14 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Torbjorn Norbye 2010-05-20 20:51:36 UTC
Consider this misformatted testcase (boiled down from a real testcase in our sourcebase):

class Foo {
    protected var active = true;
}

class Bar extends Foo {
    override var active on replace {
    if (active) {
    println("active")
    } else {
    println("not active")
    }
    }
}

When you format this, nothing happens (e.g. the println statements are not indented).

If you remove the "override" keyword, then it does format it properly into

class Foo {
    protected var active = true;
}

class Bar extends Foo {
    /*override*/ var active on replace {
        if (active) {
            println("active")
        } else {
            println("not active")
        }
    }
}



(This is with the latest formatting fixes as of JavaFX repository changeset 9f90359f8d24)
Comment 1 Anton Chechel 2010-05-31 13:24:07 UTC

*** This bug has been marked as a duplicate of bug 184262 ***
Comment 2 Alexandr Scherbatiy 2010-06-17 09:14:53 UTC
verified in NetBeans IDE Dev (Build 201006170001)