Show the behavior of print operations in the ItaniumPartialDemangler. It's a summary of what the current integration in LLDB assumes. For new users this may be a useful example.
Details
Diff Detail
- Repository
- rL LLVM
- Build Status
Buildable 21256 Build 21256: arc lint + arc unit
Event Timeline
LGTM, thanks for doing this!
unittests/Demangle/PartialDemangleTest.cpp | ||
---|---|---|
188 | Does LLDB actually pass in a N that is less than the length of Buf? Its not wrong to do that per se, realloc will sort it out, but it seems kinda strange. |
unittests/Demangle/PartialDemangleTest.cpp | ||
---|---|---|
188 | My first version used only one variable for N, so the pretended buffer size was decreasing continuously while the actual buffer remained unchanged.. That caused unnecessary allocations. I fixed that a few days ago. Basically it's these three cases to consider: |
BTW: warning I saw during recent build:
[98/790] Building CXX object tools/lldb/source/Core/CMakeFiles/lldbCore.dir/RichManglingContext.cpp.o /home/gclayton/local/src/llvm/svn/llvm/tools/lldb/source/Core/RichManglingContext.cpp: In member function ‘bool lldb_private::RichManglingContext::IsCtorOrDtor() const’: /home/gclayton/local/src/llvm/svn/llvm/tools/lldb/source/Core/RichManglingContext.cpp:77:1: warning: control reaches end of non-void function [-Wreturn-type] } ^ /home/gclayton/local/src/llvm/svn/llvm/tools/lldb/source/Core/RichManglingContext.cpp: In member function ‘bool lldb_private::RichManglingContext::IsFunction() const’: /home/gclayton/local/src/llvm/svn/llvm/tools/lldb/source/Core/RichManglingContext.cpp:89:1: warning: control reaches end of non-void function [-Wreturn-type] } ^
Does LLDB actually pass in a N that is less than the length of Buf? Its not wrong to do that per se, realloc will sort it out, but it seems kinda strange.