[PATCH] D70250: [llvm-cxxfilt] Improve strip-underscore behavior

Saleem Abdulrasool via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 18 14:48:00 PST 2019


compnerd accepted this revision.
compnerd added a comment.

Sorry about the delay on the review!



================
Comment at: llvm/tools/llvm-cxxfilt/llvm-cxxfilt.cpp:69-76
+    return true;
+  else if (NoStripUnderscore)
+    return false;
+  else
+    // If none or all of them are set, use the default value for platform.
+    // macho has symbols prefix with "_" so strip by default.
+    return Triple(sys::getProcessTriple()).isOSBinFormatMachO();
----------------
Please rewrite this as:

```
  if (StripUnderscore)
    return true;
  if (NoStripUnderscore)
    return false;
  return Triple(sys::getProcessTriple()).isOSBinFormatMachO();
```


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D70250





More information about the llvm-commits mailing list