summaryrefslogtreecommitdiff
path: root/www/cxx_dr_status.html
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2019-10-06 18:40:59 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2019-10-06 18:40:59 +0000
commitc059e0ac05e9795b065bbbe18159f52fdf1f7086 (patch)
treeb01bf736ea20a3c7648a60de069ab9e0793983a3 /www/cxx_dr_status.html
parent6a33e2a9d3d19ba43990dbae7e00f699ac5eee01 (diff)
downloadclang-c059e0ac05e9795b065bbbe18159f52fdf1f7086.tar.gz
[Sema] Avoids an assertion failure when an invalid conversion declaration is used
Summary: When using a user-defined conversion function template with a deduced return type the compiler gives a set of warnings: ``` bug.cc:252:44: error: cannot specify any part of a return type in the declaration of a conversion function; use an alias template to declare a conversion to 'auto (Ts &&...) const' template <typename... Ts> operator auto()(Ts &&... xs) const; ^~~~~~~~~~~~~~~~~~~ bug.cc:252:29: error: conversion function cannot convert to a function type template <typename... Ts> operator auto()(Ts &&... xs) const; ^ error: pointer to function type cannot have 'const' qualifier ``` after which it triggers an assertion failure. It seems the last error is incorrect and doesn't have any location information. This patch stops the compilation after the second warning. Fixes bug 31422. Patch by Mark de Wever! Reviewers: rsmith Reviewed By: rsmith Subscribers: bbannier, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D64820 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@373862 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'www/cxx_dr_status.html')
0 files changed, 0 insertions, 0 deletions