This revision was automatically updated to reflect the committed changes.
Closed by commit rL362844: Fix lit tests on Windows related to CR+LF (authored 
by amccarth, committed by ).
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

Changed prior to commit:
  https://reviews.llvm.org/D62759?vs=202505&id=203623#toc

Repository:
  rL LLVM

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

https://reviews.llvm.org/D62759

Files:
  lldb/trunk/source/Utility/Args.cpp
  lldb/trunk/tools/lldb-test/lldb-test.cpp


Index: lldb/trunk/tools/lldb-test/lldb-test.cpp
===================================================================
--- lldb/trunk/tools/lldb-test/lldb-test.cpp
+++ lldb/trunk/tools/lldb-test/lldb-test.cpp
@@ -312,7 +312,7 @@
   while (!Rest.empty()) {
     StringRef Line;
     std::tie(Line, Rest) = Rest.split('\n');
-    Line = Line.ltrim();
+    Line = Line.ltrim().rtrim();
     if (Line.empty() || Line[0] == '#')
       continue;
 
@@ -939,7 +939,7 @@
   while (!Rest.empty()) {
     StringRef Line;
     std::tie(Line, Rest) = Rest.split('\n');
-    Line = Line.ltrim();
+    Line = Line.ltrim().rtrim();
 
     if (Line.empty() || Line[0] == '#')
       continue;
Index: lldb/trunk/source/Utility/Args.cpp
===================================================================
--- lldb/trunk/source/Utility/Args.cpp
+++ lldb/trunk/source/Utility/Args.cpp
@@ -95,7 +95,7 @@
   bool arg_complete = false;
   do {
     // Skip over over regular characters and append them.
-    size_t regular = command.find_first_of(" \t\"'`\\");
+    size_t regular = command.find_first_of(" \t\r\"'`\\");
     arg += command.substr(0, regular);
     command = command.substr(regular);
 
@@ -123,6 +123,7 @@
 
     case ' ':
     case '\t':
+    case '\r':
       // We are not inside any quotes, we just found a space after an argument.
       // We are done.
       arg_complete = true;


Index: lldb/trunk/tools/lldb-test/lldb-test.cpp
===================================================================
--- lldb/trunk/tools/lldb-test/lldb-test.cpp
+++ lldb/trunk/tools/lldb-test/lldb-test.cpp
@@ -312,7 +312,7 @@
   while (!Rest.empty()) {
     StringRef Line;
     std::tie(Line, Rest) = Rest.split('\n');
-    Line = Line.ltrim();
+    Line = Line.ltrim().rtrim();
     if (Line.empty() || Line[0] == '#')
       continue;
 
@@ -939,7 +939,7 @@
   while (!Rest.empty()) {
     StringRef Line;
     std::tie(Line, Rest) = Rest.split('\n');
-    Line = Line.ltrim();
+    Line = Line.ltrim().rtrim();
 
     if (Line.empty() || Line[0] == '#')
       continue;
Index: lldb/trunk/source/Utility/Args.cpp
===================================================================
--- lldb/trunk/source/Utility/Args.cpp
+++ lldb/trunk/source/Utility/Args.cpp
@@ -95,7 +95,7 @@
   bool arg_complete = false;
   do {
     // Skip over over regular characters and append them.
-    size_t regular = command.find_first_of(" \t\"'`\\");
+    size_t regular = command.find_first_of(" \t\r\"'`\\");
     arg += command.substr(0, regular);
     command = command.substr(regular);
 
@@ -123,6 +123,7 @@
 
     case ' ':
     case '\t':
+    case '\r':
       // We are not inside any quotes, we just found a space after an argument.
       // We are done.
       arg_complete = true;
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
  • [Lldb-commits] [PATCH] D6... Adrian McCarthy via Phabricator via lldb-commits
    • [Lldb-commits] [PATC... Adrian McCarthy via Phabricator via lldb-commits

Reply via email to