davide added a comment.
Herald added a subscriber: jdoerfert.
Herald added a project: LLVM.

Pavel, this broke unicode handling for lldb on MacOS. If you type something in 
the lldb cmdline, it won't print the right character but a series of unicode 
sequences.
The main concern is that this also breaks the Swift REPL (powered by lldb).

Looks like something like this:

  $ git diff
  diff --git a/lldb/include/lldb/Host/Editline.h 
b/lldb/include/lldb/Host/Editline.h
  index cb40f1e6917..e53991c450f 100644
  --- a/lldb/include/lldb/Host/Editline.h
  +++ b/lldb/include/lldb/Host/Editline.h
  @@ -51,6 +51,7 @@
   #include <string>
   #include <vector>
   
  +#include "lldb/Host/Config.h"
   #include "lldb/Host/ConnectionFileDescriptor.h"
   #include "lldb/Host/Predicate.h"
   #include "lldb/Utility/FileSpec.h"

"fixes" the CMake build. I'm seeing failures if I apply the same patch to the 
Xcode project.

  In file included from /Users/davide/lldb/source/Host/common/Editline.cpp:14:
  /Users/davide/lldb/include/lldb/Host/Editline.h:330:29: error: no member 
named 'codecvt_utf8' in namespace 'std'
    std::wstring_convert<std::codecvt_utf8<wchar_t>> m_utf8conv;
                         ~~~~~^
  /Users/davide/lldb/include/lldb/Host/Editline.h:330:49: error: expected '(' 
for function-style cast or type construction
    std::wstring_convert<std::codecvt_utf8<wchar_t>> m_utf8conv;
                                           ~~~~~~~^
  /Users/davide/lldb/source/Host/common/Editline.cpp:413:24: error: use of 
undeclared identifier 'm_utf8conv'
      lines.AppendString(m_utf8conv.to_bytes(line));
                         ^
  /Users/davide/lldb/source/Host/common/Editline.cpp:577:26: error: use of 
undeclared identifier 'm_utf8conv'
        lines.AppendString(m_utf8conv.to_bytes(new_line_fragment));
                           ^
  /Users/davide/lldb/source/Host/common/Editline.cpp:628:30: error: use of 
undeclared identifier 'm_utf8conv'
                               m_utf8conv.from_bytes(lines[index]));
                               ^
  /Users/davide/lldb/source/Host/common/Editline.cpp:813:41: error: use of 
undeclared identifier 'm_utf8conv'
    m_input_lines[m_current_line_index] = m_utf8conv.from_bytes(currentLine);
                                          ^
  /Users/davide/lldb/source/Host/common/Editline.cpp:1319:14: error: use of 
undeclared identifier 'm_utf8conv'
        line = m_utf8conv.to_bytes(SplitLines(input)[0]);
               ^
  /Users/davide/lldb/source/Host/common/Editline.cpp:1389:8: error: no member 
named 'codecvt_utf8' in namespace 'std'
    std::codecvt_utf8<wchar_t> cvt;
    ~~~~~^
  /Users/davide/lldb/source/Host/common/Editline.cpp:1389:28: error: expected 
'(' for function-style cast or type construction
    std::codecvt_utf8<wchar_t> cvt;
                      ~~~~~~~^
  /Users/davide/lldb/source/Host/common/Editline.cpp:1389:30: error: use of 
undeclared identifier 'cvt'
    std::codecvt_utf8<wchar_t> cvt;
                               ^
  /Users/davide/lldb/source/Host/common/Editline.cpp:1396:13: error: use of 
undeclared identifier 'cvt'
      switch (cvt.in(state, input.begin(), input.end(), from_next, &out, &out + 
1,
              ^
  11 errors generated.

Can you please take a look? If you need anything from me, just let me know!


Repository:
  rL LLVM

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D47625/new/

https://reviews.llvm.org/D47625



_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
  • [Lldb-commits] [PATCH] D4... Davide Italiano via Phabricator via lldb-commits

Reply via email to