[prev in list] [next in list] [prev in thread] [next in thread] 

List:       llvm-bugs
Subject:    [llvm-bugs] [Bug 63617] Missing "no return statement in constexpr function" error for a templated co
From:       LLVM Bugs via llvm-bugs <llvm-bugs () lists ! llvm ! org>
Date:       2023-06-30 9:40:36
Message-ID: 20230630094036.2e009f4a749f3ea0 () email ! llvm ! org
[Download RAW message or body]

[Attachment #2 (text/html)]

<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/63617>63617</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            Missing &quot;no return statement in constexpr function&quot; error for a \
templated constexpr function  </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            new issue
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          strimo378
      </td>
    </tr>
</table>

<pre>
    Hi all,

I found a case where clang issues a warning about &quot;non-void function does not \
return a value&quot; for a constexpr function. For constexpr function, clang \
typically issues an error and no warning.

The code to generate the warning is

```
template &lt;class...&gt; struct a {};
template &lt;class... b&gt; constexpr a&lt;typename b ::c...&gt; d() {}
auto e = d();

//constexpr int f() {}
```

Or a link to compiler explorer https://godbolt.org/z/1rd4W8exr
</pre>
<img width="1px" height="1px" alt="" \
src="http://email.email.llvm.org/o/eJx0kk9v2zAMxT8NfSFqKJLrOAcf2mTGdhh2GbCzLNGJNlkyJLp \
t9ukH51-LIgMCBrbJx_ekn87Z7QNRC4_P8Lgr9MyHmNrMyY1RrZuij_bYfnWovQe5BbED8XSu33CIc7Co0ehM- \
HqgRGi8Dnt0Oc-UUeOrTsGFPeo-zowgZYjh4SU6i8McDLsY0EbKGCJjIp5TQI0v2s8EUuIQ06IeQ2Z6m9JtpsQ \
upjvvQW4vBvg4OaO9P96sBKSUFr1gMcSrsfJjoJ8HQhMtIUfcU6CkmZAPdEvh8sd2qMXld3pkGie_TIDaGq9zL \
ssS1BfMnGbDqBHWz7DegXr-fz_2y8R7MA1qy8eJgh4JewT1BOrJXIQtyAbk5qp7EtUzR1wkd9fPt32XKjuQ3fs \
GFxiHO0Kfwp3rj-U6vAt_lhMycZycp4T0NvmYKOGBecqLx9OOfbR99FzGtAfZ_QXZrZKtfjX0lgrbKrtRG11Qu \
6qbZrVqhKqLQzvUldxURtnH9bBuhF5VpjHSDIOy1pi-LlwrhVSiVkJsKqHqUpIQm6HS62ozKNICKkGjdr70_mV \
cdhcnANpa1at14XVPPp9YlzLQ65kOkHJBP7XLzEM_7zNUwrvM-V2FHXtqv7ucFxBOIF-BzayZRgqMLtyFUl7QO-N8vXd7p7eYk28_HaPjw9yXJo4gu8XO5e9hSvE3GQbZnREH2Z1C_gsAAP__s8c16A">



[Attachment #3 (text/plain)]

_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic