jls suggestions modifier order

今天在修理 check style 的時候,跑出一些奇怪的錯誤,原來是 static 寫在 abstract 之前,或是 final 寫在 static 之前。

查了一下,原來這些 modifier 是有建議順序的。

Checks that the order of modifiers conforms to the suggestions in the Java Language specification, sections 8.1.1, 8.3.1 and 8.4.3. The correct order is:

ref: http://checkstyle.sourceforge.net/config_modifier.html

Posted in Computers

Leave a Reply

Your email address will not be published.