[Lldb-commits] [PATCH] D48084: [FileSpec] Delegate common operations to llvm::sys::path
Zachary Turner via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Tue Jun 12 10:29:26 PDT 2018
zturner accepted this revision.
zturner added a comment.
This revision is now accepted and ready to land.
Looks like good cleanup to me, thanks!
================
Comment at: source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp:2593-2596
+ if (::strcmp(extension.GetCString(), ".py") == 0)
basename.resize(basename.length() - 3);
- else if (::strcmp(extension.GetCString(), "pyc") == 0)
+ else if (::strcmp(extension.GetCString(), ".pyc") == 0)
basename.resize(basename.length() - 4);
----------------
Can you change these `strcmp` operations to `StringRef` calls? Might as well do some cleanup if we're here anyway.
Repository:
rL LLVM
https://reviews.llvm.org/D48084
More information about the lldb-commits
mailing list