diff options
author | Sebastian Redl <sebastian.redl@getdesigned.at> | 2012-02-12 16:37:24 +0000 |
---|---|---|
committer | Sebastian Redl <sebastian.redl@getdesigned.at> | 2012-02-12 16:37:24 +0000 |
commit | 168319c81b8f4e7addf36ad15ef24919faf23504 (patch) | |
tree | 4adce37b8c3d38972f20ef9e2f507dc19eea17cc /include/clang/Sema/Initialization.h | |
parent | 8275fc0ba70b29a116e0892e582a8fb21124abf1 (diff) |
Employ DirectList initialized entities to properly sort through some initialization edge cases.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150342 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Sema/Initialization.h')
-rw-r--r-- | include/clang/Sema/Initialization.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/include/clang/Sema/Initialization.h b/include/clang/Sema/Initialization.h index 853f8897f2..dde46a2ff4 100644 --- a/include/clang/Sema/Initialization.h +++ b/include/clang/Sema/Initialization.h @@ -470,9 +470,13 @@ public: assert(Kind == SIK_Copy && "Only copy initialization has an '='"); return Locations[1]; } - + bool isCopyInit() const { return Kind == SIK_Copy; } - + + /// \brief Retrieve whether this initialization allows the use of explicit + /// constructors. + bool AllowExplicit() const { return !isCopyInit(); } + /// \brief Retrieve the source range containing the locations of the open /// and closing parentheses for value and direct initializations. SourceRange getParenRange() const { |