Last Comment Bug 797794 - Preprocessor.py -Fslashslash does'nt work
: Preprocessor.py -Fslashslash does'nt work
Status: RESOLVED FIXED
:
Product: Core
Classification: Components
Component: Build Config (show other bugs)
: Trunk
: x86 Windows XP
: -- normal (vote)
: mozilla19
Assigned To: Taro Matsuzawa
:
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-10-04 03:10 PDT by teramako
Modified: 2012-11-08 02:38 PST (History)
5 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
test script (21 bytes, text/plain)
2012-10-05 03:17 PDT, teramako
no flags Details
Fix for -Fslashslash option. (808 bytes, patch)
2012-10-10 21:03 PDT, Taro Matsuzawa
ted: review+
Details | Diff | Review

Description teramako 2012-10-04 03:10:11 PDT
User Agent: Opera/9.80 (Windows NT 5.1; U; Edition Next; ja) Presto/2.11.310 Version/12.50

Steps to reproduce:

python Preprocessor.py -Fslashslash doesn't work


Actual results:

$ cat test.js
// comment

$ python Preprocessor.py -Fslashslash test.js

Traceback (most recent call last):
  File "Preprocessor.py", line 475, in <module>
    main()
  File "Preprocessor.py", line 460, in main
    pp.handleCommandLine(None, True)
  File "Preprocessor.py", line 157, in handleCommandLine
    self.do_include(f, False)
  File "Preprocessor.py", line 445, in do_include
    self.handleLine(l)
  File "Preprocessor.py", line 226, in handleLine
    self.write(aLine)
  File "Preprocessor.py", line 136, in write
    filteredLine = self.applyFilters(aLine)
  File "Preprocessor.py", line 121, in applyFilters
    aLine = f[1](aLine)
  File "Preprocessor.py", line 385, in filter_slashslash
    [aLine, rest] = aLine.split('//', 1)
ValueError: need more than 1 value to unpack
Comment 1 teramako 2012-10-05 03:17:06 PDT
Created attachment 668381 [details]
test script
Comment 2 ABE Hiroki (:hATrayflood) 2012-10-05 03:30:47 PDT
this error caused by blank line with -Fslashslash option.
double slashed comment does not related.
Comment 3 Taro Matsuzawa 2012-10-10 21:03:24 PDT
Created attachment 670235 [details] [diff] [review]
Fix for -Fslashslash option.
Comment 4 Masatoshi Kimura [:emk] 2012-10-10 22:32:54 PDT
You need to assign a reviewer. (Maybe Ted?)
Comment 5 Ted Mielczarek [:ted.mielczarek] 2012-10-31 11:26:05 PDT
Comment on attachment 670235 [details] [diff] [review]
Fix for -Fslashslash option.

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

Sorry for the review delay! This is fine, but it would be nice to have a unit test for it.
Comment 6 Makoto Kato [:m_kato] (PTO 6/20-21, 6/24) 2012-11-07 17:37:38 PST
https://hg.mozilla.org/integration/mozilla-inbound/rev/1b344f7a2e81
Comment 7 Makoto Kato [:m_kato] (PTO 6/20-21, 6/24) 2012-11-07 18:00:19 PST
bustage fix (we have to sync config/* and js/src/config/*)
https://hg.mozilla.org/integration/mozilla-inbound/rev/30366a70c015

Note You need to log in before you can comment on or make changes to this bug.