summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/MachineOperand.cpp
diff options
context:
space:
mode:
authorRaphael Isemann <teemperor@gmail.com>2018-09-27 10:12:54 +0000
committerRaphael Isemann <teemperor@gmail.com>2018-09-27 10:12:54 +0000
commitdababf70e2df03214b19c0bfaeb6091923171ef6 (patch)
treeb3d8eab9026b8e5fa6c571f007ad9cc526bae30a /llvm/lib/CodeGen/MachineOperand.cpp
parent436c0127025aab9e470cb20f678c4ecf28cfa765 (diff)
downloadbcm5719-llvm-dababf70e2df03214b19c0bfaeb6091923171ef6.tar.gz
bcm5719-llvm-dababf70e2df03214b19c0bfaeb6091923171ef6.zip
Refactor ClangUserExpression::GetLanguageForExpr
Summary: The `ClangUserExpression::GetLanguageForExpr` method is currently a big source of sadness, as it's name implies that it's an accessor method, but it actually is also initializing some variables that we need for parsing. This caused that we currently call this getter just for it's side effects while ignoring it's return value, which is confusing for the reader. This patch renames it to `UpdateLanguageForExpr` and merges all calls to the method into a single call in `ClangUserExpression::PrepareForParsing` (as calling this method is anyway mandatory for parsing to succeed) While looking at the code, I also found that we actually have two language variables in this class hierarchy. The normal `Language` from the UserExpression class and the `LanguageForExpr` that we implemented in this subclass. Both don't seem to actually contain the same value, so we probably should look at this next. Reviewers: xbolva00 Reviewed By: xbolva00 Subscribers: lldb-commits Differential Revision: https://reviews.llvm.org/D52561 llvm-svn: 343191
Diffstat (limited to 'llvm/lib/CodeGen/MachineOperand.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud