https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100079
--- Comment #3 from Lukas Böger <mail at lboeger dot de> --- I believe it should be valid. The revision which turns the snippet from rejection into an ICE makes sense, as this is about class-type instances as non-type template parameters.