From d2090e19a93fca9b5015d3a6978d7079e1414e13 Mon Sep 17 00:00:00 2001 From: Olivier Goffart Date: Tue, 10 Apr 2012 13:38:41 +0200 Subject: moc: Fix parsing of the empty preprocessor command MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When encountering a null preprocessing directive (which is supposed to be ignored), the moc preprocessor will leave a PP_NEWLINE token in the token stream. That will confuse the parser. The PP_NEWLINE token need to be ignored in the preprocessing phase. Task-number: QTBUG-22717 Change-Id: I1e502a7e5bc6fa8ce2f82109ba7199b95747ff0a Reviewed-by: João Abecasis Reviewed-by: Bradley T. Hughes --- tests/auto/tools/moc/tst_moc.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'tests/auto/tools') diff --git a/tests/auto/tools/moc/tst_moc.cpp b/tests/auto/tools/moc/tst_moc.cpp index 49095048bf..ecd9dc599e 100644 --- a/tests/auto/tools/moc/tst_moc.cpp +++ b/tests/auto/tools/moc/tst_moc.cpp @@ -368,6 +368,13 @@ signals: void signalInIf3(); #endif +# //QTBUG-22717 + # /* */ +# + + # \ + +// public slots: void const slotWithSillyConst() {} -- cgit v1.2.3