Add function for testing string attributes to InvokeInst and CallSite. NFC.
[oota-llvm.git] / include / llvm / IR / CallSite.h
index f4b8a8a5a1c93b33edf22359c8de96ed577c5ea4..f7bfb47a5b4446edbd495b979f6350cf40a03df5 100644 (file)
@@ -310,6 +310,11 @@ public:
     CALLSITE_DELEGATE_GETTER(hasFnAttr(A));
   }
 
+  /// \brief Return true if this function has the given attribute.
+  bool hasFnAttr(StringRef A) const {
+    CALLSITE_DELEGATE_GETTER(hasFnAttr(A));
+  }
+
   /// \brief Return true if the call or the callee has the given attribute.
   bool paramHasAttr(unsigned i, Attribute::AttrKind A) const {
     CALLSITE_DELEGATE_GETTER(paramHasAttr(i, A));