]> granicus.if.org Git - clang/commitdiff
Add getDeserializationListener to ASTReader
authorYuka Takahashi <yukatkh@gmail.com>
Thu, 26 Apr 2018 15:09:13 +0000 (15:09 +0000)
committerYuka Takahashi <yukatkh@gmail.com>
Thu, 26 Apr 2018 15:09:13 +0000 (15:09 +0000)
Summary:
We need to know if ASTReader already has a DeserializationListner or
not, and this also helps to create a multiplexing deserialization
listener if there is one already attached.

Reviewers: v.g.vassilev, rsmith, dblaikie, thakis

Subscribers: cfe-commits

Differential Revision: https://reviews.llvm.org/D45921

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@330946 91177308-0d34-0410-b5e6-96231b3b80d8

include/clang/Serialization/ASTReader.h

index 01cd055e766fdc5b9e7a9ad0ea133324fdcbe7c9..ba9fc0605bbea5b0ebcf1a145e0bcb8f19b093d9 100644 (file)
@@ -1599,6 +1599,11 @@ public:
   void setDeserializationListener(ASTDeserializationListener *Listener,
                                   bool TakeOwnership = false);
 
+  /// \brief Get the AST deserialization listener.
+  ASTDeserializationListener *getDeserializationListener() {
+    return DeserializationListener;
+  }
+
   /// \brief Determine whether this AST reader has a global index.
   bool hasGlobalIndex() const { return (bool)GlobalIndex; }