Bug 114497 - Alias CTAD crashes
Summary: Alias CTAD crashes
Status: RESOLVED DUPLICATE of bug 114377
Alias: None
Product: gcc
Classification: Unclassified
Component: c++ (show other bugs)
Version: 14.0
: P3 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords: ice-on-valid-code
Depends on:
Blocks:
 
Reported: 2024-03-27 10:35 UTC by Haojian Wu
Modified: 2024-03-27 14:05 UTC (History)
2 users (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Haojian Wu 2024-03-27 10:35:10 UTC
Crashes on gcc trunk.

See https://gcc.godbolt.org/z/EErMqe44o

```
template <template <typename> typename T>
struct K {};

template <typename U, int...N>
class Foo {};

template <template<typename> typename TTP,
          int...N>
using Bar = Foo<K<TTP>, N...>; 

template <class T>
class Container {};
Bar t = Foo<K<Container>, 1>();

```
Comment 1 Centurion 2024-03-27 11:35:34 UTC
Looks like P114377 dublicate. Here is same problem with missed TEMPLATE_DECL in condition: parm gets nullptr from DECL_INITIAL, instead of getting TEMPLATE_TEMPLATE_PARM from TREE_TYPE.

https://gcc.gnu.org/pipermail/gcc-patches/2024-March/648338.html
Comment 2 Patrick Palka 2024-03-27 14:05:35 UTC
Great, let's close this as a dup then.

*** This bug has been marked as a duplicate of bug 114377 ***