Bug 55576 - Compilation fails because of stricter warning(s) with GCC 4.5 compiler
Summary: Compilation fails because of stricter warning(s) with GCC 4.5 compiler
Status: RESOLVED DUPLICATE of bug 57822
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC Linux
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-03-02 07:25 PST by Christoph
Modified: 2011-04-05 03:13 PDT (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Christoph 2011-03-02 07:25:29 PST
Trying to build svn r79936 via "build-webkit --qt", I get the following compilation error:

Source/JavaScriptCore/yarr/YarrParser.h:454:64: error: ‘characterClassConstructor.JSC::Yarr::Parser<JSC::Yarr::SyntaxChecker>::CharacterClassParserDelegate::m_character’ may be used uninitialized in this function

As discussed with Ossy on #webkit, it might be caused by stricter warnings of the GCC 4.5 compiler. I am using the openSUSE 11.3 compiler, which is "gcc (SUSE Linux) 4.5.0 20100604 [gcc-4_5-branch revision 160292]".

Full error is below:

make[1]: Entering directory `/local/build/webkit/Release/JavaScriptCore'
g++ -c -pipe -Wall -Wextra -Wreturn-type -fno-strict-aliasing -Wcast-align -Wchar-subscripts -Wformat-security -Wreturn-type -Wno-unused-parameter -Wno-sign-compare -Wno-switch -Wno-switch-enum -Wundef -Wmissing-noreturn -Winit-self -Werror -fno-stack-protector -O3 -fvisibility=hidden -fvisibility-inlines-hidden -fPIC -D_REENTRANT -DBUILDING_QT__=1 -DNDEBUG -DXP_UNIX -DBUILDING_JavaScriptCore -DBUILDING_WTF -DQT_NO_DEBUG -DQT_CORE_LIB -DQT_SHARED -I../../../../Qt4/qt-4.7/mkspecs/linux-g++ -I../../../../git/Qt/webkit/Source/JavaScriptCore -I../../../../Qt4/qt-4.7/include/QtCore -I../../../../Qt4/qt-4.7/include -I../../../../git/Qt/webkit/Source/JavaScriptCore -I../../../../git/Qt/webkit/Source -I../../../../git/Qt/webkit/Source/ThirdParty -I../../../../git/Qt/webkit/Source/JavaScriptCore/assembler -I../../../../git/Qt/webkit/Source/JavaScriptCore/bytecode -I../../../../git/Qt/webkit/Source/JavaScriptCore/bytecompiler -I../../../../git/Qt/webkit/Source/JavaScriptCore/collector/handles -I../../../../git/Qt/webkit/Source/JavaScriptCore/debugger -I../../../../git/Qt/webkit/Source/JavaScriptCore/interpreter -I../../../../git/Qt/webkit/Source/JavaScriptCore/jit -I../../../../git/Qt/webkit/Source/JavaScriptCore/parser -I../../../../git/Qt/webkit/Source/JavaScriptCore/profiler -I../../../../git/Qt/webkit/Source/JavaScriptCore/runtime -I../../../../git/Qt/webkit/Source/JavaScriptCore/wtf -I../../../../git/Qt/webkit/Source/JavaScriptCore/wtf/gobject -I/local/git/Qt/webkit/Source/JavaScriptCore/wtf/symbian -I../../../../git/Qt/webkit/Source/JavaScriptCore/wtf/unicode -I../../../../git/Qt/webkit/Source/JavaScriptCore/yarr -I../../../../git/Qt/webkit/Source/JavaScriptCore/API -I../../../../git/Qt/webkit/Source/JavaScriptCore/ForwardingHeaders -Igenerated -I../include/QtWebKit -I../include -I. -I../../../../git/Qt/webkit/Source/JavaScriptCore -I. -o obj/release/YarrSyntaxChecker.o ../../../../git/Qt/webkit/Source/JavaScriptCore/yarr/YarrSyntaxChecker.cpp
cc1plus: warnings being treated as errors
In file included from ../../../../git/Qt/webkit/Source/JavaScriptCore/yarr/YarrSyntaxChecker.cpp:29:0:
../../../../git/Qt/webkit/Source/JavaScriptCore/yarr/YarrParser.h: In member function ‘void JSC::Yarr::Parser<Delegate>::parseTokens() [with Delegate = JSC::Yarr::SyntaxChecker]’:
../../../../git/Qt/webkit/Source/JavaScriptCore/yarr/YarrParser.h:454:64: error: ‘characterClassConstructor.JSC::Yarr::Parser<JSC::Yarr::SyntaxChecker>::CharacterClassParserDelegate::m_character’ may be used uninitialized in this function
../../../../git/Qt/webkit/Source/JavaScriptCore/yarr/YarrParser.h:454:64: note: ‘characterClassConstructor.JSC::Yarr::Parser<JSC::Yarr::SyntaxChecker>::CharacterClassParserDelegate::m_character’ was declared here
make[1]: *** [obj/release/YarrSyntaxChecker.o] Fehler 1
make[1]: Leaving directory `/local/build/webkit/Release/JavaScriptCore'
make: *** [sub-JavaScriptCore-JavaScriptCore-pro-make_default-ordered] Fehler 2
Comment 1 Csaba Osztrogonác 2011-03-02 07:31:00 PST
I think we should initialize m_character in constructor to make gcc happier.
Comment 2 Csaba Osztrogonác 2011-04-05 02:21:16 PDT
*** Bug 57822 has been marked as a duplicate of this bug. ***
Comment 3 Csaba Osztrogonác 2011-04-05 03:13:37 PDT
Mark as duplicate, because there is a proposed patch on the other bug.

*** This bug has been marked as a duplicate of bug 57822 ***