[cfe-dev] getFunctionType in CXXMethodDecl

victor pedretti_86 at hotmail.com
Thu Feb 19 01:19:48 PST 2015


Thank you Richard, it worked perfect. I was wrong with the method hasNoexceptExceptionSpec: isNothrow is the method I was looking for.

Date: Wed, 18 Feb 2015 13:04:25 -0800
Subject: Re: [cfe-dev] getFunctionType in CXXMethodDecl
From: richard at metafoo.co.uk
To: pedretti_86 at hotmail.com
CC: cfe-dev at cs.uiuc.edu

On Wed, Feb 18, 2015 at 12:14 PM, victor <pedretti_86 at hotmail.com> wrote:



Hi,

I want to know if a method is marked as "hasNoexceptExceptionSpec" in FunctionProtoType. To that end, I was trying to call getFunctionType() on the method, but:

"error: no member named 'getFunctionType' in 'clang::CXXMethodDecl' "

I'm using clang 3.4, is this method missing in this version? Is there another simpler way to know if a function is "noexcept"?
MD->getType()->castAs<FunctionProtoType>()->isNothrow(Ctx) 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20150219/10240836/attachment.html>


More information about the cfe-dev mailing list