[lldb-dev] -Werror and lldb

Eric Christopher echristo at gmail.com
Tue Sep 9 00:03:31 PDT 2014


So for fun a bit ago I decided to see what it would take to build lldb
-Werror free as a subproject of llvm (in llvm/tools alongside clang of
course) and fixed up a bunch of warnings/errors that happen.

lldb-mi has the last set of warnings that I wasn't able to trivially fix up
as it would require rewriting a bit of it so I'll just send mail to the
authors and hope it happens :)

Here's the current problem:

/usr/local/google/home/echristo/sources/llvm/tools/lldb/tools/lldb-mi/MIUtilVariant.h:120:16:
error: 'CMIUtilVariant::CDataObject<CMIUtilString>::Copy' hides overloaded
virtual
      function [-Werror,-Woverloaded-virtual]
                virtual void Copy( const CDataObject & vrOther );
                             ^
/usr/local/google/home/echristo/sources/llvm/tools/lldb/tools/lldb-mi/MIUtilVariant.h:266:22:
note: in instantiation of template class
'CMIUtilVariant::CDataObject<CMIUtilString>'
      requested here
        m_pDataObject = new CDataObject< T >(  vArg );
                            ^
/usr/local/google/home/echristo/sources/llvm/tools/lldb/tools/lldb-mi/MIUtilMapIdToVariant.h:99:8:
note: in instantiation of function template specialization
      'CMIUtilVariant::Set<CMIUtilString>' requested here
                data.Set< T >( vData );
                     ^
/usr/local/google/home/echristo/sources/llvm/tools/lldb/tools/lldb-mi/MICmnLLDBDebugSessionInfo.h:205:28:
note: in instantiation of function template specialization
      'CMIUtilMapIdToVariant::Add<CMIUtilString>' requested here
        if( !m_mapIdToSessionData.Add< T >( vKey, vData ) )
                                  ^
/usr/local/google/home/echristo/sources/llvm/tools/lldb/tools/lldb-mi/MICmdCmdEnviro.cpp:93:32:
note: in instantiation of function template specialization
      'CMICmnLLDBDebugSessionInfo::SharedDataAdd<CMIUtilString>' requested
here
                if( !m_rLLDBDebugSessionInfo.SharedDataAdd< CMIUtilString
>( rStrKeyWkDir, strWkDir ) )
                                             ^
/usr/local/google/home/echristo/sources/llvm/tools/lldb/tools/lldb-mi/MIUtilVariant.h:85:16:
note: hidden overloaded virtual function
'CMIUtilVariant::CDataObjectBase::Copy' declared
      here: type mismatch at 1st parameter ('const
CMIUtilVariant::CDataObjectBase &' vs 'const
CMIUtilVariant::CDataObject<CMIUtilString> &')
                virtual void Copy( const CDataObjectBase & vrOther );


which requires a bit of rewriting to get past. It would be very nice if
this were to happen since it would allow lldb to take advantage of the
newer warnings etc while being able to be built as part of the build bots a
little easier as well.

Thanks!

-eric
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/lldb-dev/attachments/20140909/0a75dafd/attachment.html>


More information about the lldb-dev mailing list