[PATCH] D17641: [Polly] [MemAccInst] Delete all the assignment operators, as they are not need.
Hongbin Zheng via llvm-commits
llvm-commits at lists.llvm.org
Fri Feb 26 09:08:48 PST 2016
etherzhhb marked 3 inline comments as done.
================
Comment at: include/polly/Support/ScopHelper.h:68
@@ -67,3 +67,3 @@
private:
- llvm::Instruction *I;
+ llvm::Instruction *const I;
----------------
Meinersbur wrote:
> etherzhhb wrote:
> > Meinersbur wrote:
> > > The constness of the Instruction pointed to should be determined by the user of MemAccInst by declaring it const, e.g. `const MemAccInst`.
> > This make sense. Could we use MemAccInst just like "const MemAccInst"?
> I tired to make MemAccInst mimic a (non-existing) pointer to a base class of LostInst/StoreInst. D17250 makes it even more so. As such I try to keep MemAccInst behaving like a (smart) pointer which includes reassignment and declaring it as const when necessary.
>
> Smart pointers a well-known idiom in that most C++ programmers know. I'd argue differing from a known idiom would be more confusing than changing the pointee.
Ok
Repository:
rL LLVM
http://reviews.llvm.org/D17641
More information about the llvm-commits
mailing list