Re: which compiler is right (either to compile or to barf)...

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



在 2022/12/1 12:51, leon zadorin via Gcc-help 写道:
Hi everyone,

I would be interested to hear the opinions of C++ standard experts on which
compiler is correctly dealing with the below code (GCC 12.2 -std=c++20
  compiles fine, MSVC19.33 /std:c++20 compiles fine, Clang 15.0.0 -std=c++20
barfs)


I think this is a bug in Clang. Instantiation of `shared_ptr<T<U>>` is not meant to instantiate `T<U>`. Your code actually compiles fine if the definition of `J` was not provided.

--
Best regards,
LIU Hao

Attachment: OpenPGP_signature
Description: OpenPGP digital signature


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux