Closed Bug 1152551 Opened 9 years ago Closed 9 years ago

Fix mode lines in dom/

Categories

(Core :: DOM: Core & HTML, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla40
Tracking Status
firefox40 --- fixed

People

(Reporter: mccr8, Assigned: mccr8)

References

Details

Attachments

(4 files, 5 obsolete files)

See also bug 1151541.  I'm going to skip dom/media for now because there's a lot of code in there, and a lot of it is imported.  I have a script that semi-automatically does this fixup.
Attached patch Fix mode lines in dom/ WIP (obsolete) — Splinter Review
Attached patch Fix mode lines in dom/. WIP (obsolete) — Splinter Review
The script had a bug in the case where the MPL was in the same comment as the mode lines, with existing mode lines, and there was an empty line in between the mode line and the license.  This version compiles for me locally.
Attachment #8589935 - Attachment is obsolete: true
Attached patch Fix mode lines in dom/. WIP (obsolete) — Splinter Review
Oops, that was only for dom/base.
Attachment #8589965 - Attachment is obsolete: true
Attached file script used to generate the patch (obsolete) —
I modified my script to find leading whitespace containing tabs. I manually fixed them. The diff -w is empty.
Attachment #8590359 - Flags: review?(amarchesini)
Actually that didn't get the one in nsXMLContentSink.cpp. I also removed all trailing whitespace from that file. As before, diff -w for this patch is empty.
Attachment #8590363 - Flags: review?(amarchesini)
Attachment #8590359 - Attachment is obsolete: true
Attachment #8590359 - Flags: review?(amarchesini)
Comment on attachment 8590363 [details] [diff] [review]
part 1 - Remove leading tabs in dom/.

Review of attachment 8590363 [details] [diff] [review]:
-----------------------------------------------------------------

Thanks for doing this.
Attachment #8590363 - Flags: review?(amarchesini) → review+
I skipped a few directories.

dom/media/* is huge, and includes a lot of imported code.

dom/camera, dom/canvas, dom/system/qt/, dom/system/gonk/ and dom/system/gonk/android_audio/ had enough of a mix of imported code and maybe some 4 space indented code along with the 2 space indented code that I didn't want to deal with it.

dom/plugins/*, dom/xslt/*, and dom/xul/* include a lot of old code that is 4 space indented, so we can't change the mode line to something for 2 space indentation.

There's also a bunch of individual files I skipped because they were four space indented or whatever.  You can look at the list fileBlackList in the script if you are curious.
Attachment #8589966 - Attachment is obsolete: true
Attachment #8589982 - Attachment is obsolete: true
jst volunteered to review this unreviewable patch.

1732 files changed, 3368 insertions(+), 2061 deletions(-)

I flipped through the entire patch myself, so I don't think it mangles anything up too horribly.  It also builds.  The script is idempotent (if you run the script on dom/ twice the second pass makes no additional changes).
Attachment #8593648 - Flags: review?(jst)
Comment on attachment 8593648 [details] [diff] [review]
part 2 - Fix mode lines in dom/.

Fun review indeed! ;) r=jst
Attachment #8593648 - Flags: review?(jst) → review+
Some more fixes.  Fairly small patch.  Nothing surprising.
Attachment #8599878 - Flags: review?(jst)
Attachment #8599878 - Flags: review?(jst) → review+
See Also: → 1412125
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.