[cfe-commits] [PATCH] Accept trailing-return-type in abstract-declarators again

Richard Smith richard at metafoo.co.uk
Mon Feb 21 16:19:05 PST 2011


Hi,

The attached patch fixes a few auto-related issues:

 * 'auto' was being rejected on abstract-declarators with trailing return
types and on typedefs with trailing return types. 'auto' is always
allowed in these cases. This was found while testing the fix for PR 9278.

 * A very poor diagnostic was being issued for auto (f() -> int): "return
type must be 'auto', not 'auto'". This is closely related to PR 9060.

 * Trailing return type handling was happening slightly too late,
resulting in the checks for functions returning arrays and functions
returning functions being missed.

Thanks,
Richard
-------------- next part --------------
A non-text attachment was scrubbed...
Name: clang-auto-abstract-trt.diff
Type: text/x-patch
Size: 10281 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20110222/92140251/attachment.bin>


More information about the cfe-commits mailing list