[Webkit-unassigned] [Bug 9671] New: Style rules not supported by autoformatters
bugzilla-daemon at opendarwin.org
bugzilla-daemon at opendarwin.org
Fri Jun 30 16:13:10 PDT 2006
http://bugzilla.opendarwin.org/show_bug.cgi?id=9671
Summary: Style rules not supported by autoformatters
Product: WebKit
Version: 420+ (nightly)
Platform: PC
OS/Version: Mac OS X 10.4
Status: NEW
Severity: normal
Priority: P2
Component: Tools
AssignedTo: webkit-unassigned at opendarwin.org
ReportedBy: mike.emmel at gmail.com
The current style rules for WebKit
http://webkit.opendarwin.org/coding/coding-style.html
Are not directly supported by available auto-code formatters astyle,indent etc.
First it would be nice to develop either a modified style guidelines that would
allow the use of at least one command line code formatter.
I've developed a set of rules for astyle that seem close.
astyle \
--mode=c \
--convert-tabs \
--indent=spaces=4 \
--brackets=linux \
--indent-switches \
--max-instatement-indent=40 \
--min-conditional-indent=4 \
--one-line=keep-statements \
--one-line=keep-blocks \
--pad=oper \
$@
But they do not work completely
namespace foo {
becomes
namespace foo
{
And if() -> if () is not supported.
Other artifacts are possbile.
The following is needed
1.) Determine the best formatter
2.) Modify formatter if needed to fit the current rules.
3.) Change the rules to follow the formatter where its difficult or impossible
to follow the current formatting rules.
Note desired formatting that is not handled by auto formatting as strong
suggestions.
Finally schedule a full reformat of the code base if desired.
--
Configure bugmail: http://bugzilla.opendarwin.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
More information about the webkit-unassigned
mailing list