diff options
| -rw-r--r-- | clang/include/clang/Sema/AttributeList.h | 5 | ||||
| -rw-r--r-- | clang/include/clang/Sema/DeclSpec.h | 10 |
2 files changed, 1 insertions, 14 deletions
diff --git a/clang/include/clang/Sema/AttributeList.h b/clang/include/clang/Sema/AttributeList.h index cf50c3e907b..6957e6dd16b 100644 --- a/clang/include/clang/Sema/AttributeList.h +++ b/clang/include/clang/Sema/AttributeList.h @@ -705,10 +705,7 @@ public: : pool(factory), list(0) { } - ParsedAttributes(ParsedAttributes &attrs) - : pool(attrs.pool), list(attrs.list) { - attrs.list = 0; - } + ParsedAttributes(const ParsedAttributes &) = delete; AttributePool &getPool() const { return pool; } diff --git a/clang/include/clang/Sema/DeclSpec.h b/clang/include/clang/Sema/DeclSpec.h index 53c18d98aef..2cd10da7180 100644 --- a/clang/include/clang/Sema/DeclSpec.h +++ b/clang/include/clang/Sema/DeclSpec.h @@ -709,22 +709,12 @@ public: void addAttributes(AttributeList *AL) { Attrs.addAll(AL); } - void setAttributes(AttributeList *AL) { - Attrs.set(AL); - } bool hasAttributes() const { return !Attrs.empty(); } ParsedAttributes &getAttributes() { return Attrs; } const ParsedAttributes &getAttributes() const { return Attrs; } - /// \brief Return the current attribute list and remove them from - /// the DeclSpec so that it doesn't own them. - ParsedAttributes takeAttributes() { - // The non-const "copy" constructor clears the operand automatically. - return Attrs; - } - void takeAttributesFrom(ParsedAttributes &attrs) { Attrs.takeAllFrom(attrs); } |

