From f2df641d9afbc3e515cfc966653ba98bf0aefed4 Mon Sep 17 00:00:00 2001 From: Changqing Jing Date: Wed, 13 May 2026 12:36:54 +0800 Subject: [PATCH 1/2] [NFC] revert msvc exclusion in wasm-type-printing The bug has been fixed in visual studio 2026 https://developercommunity.visualstudio.com/t/msvc-error-C1001:-Internal-compiler-erro/10992638?scope=follow --- src/wasm-type-printing.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/wasm-type-printing.h b/src/wasm-type-printing.h index 483c48cf0a3..e4523de965b 100644 --- a/src/wasm-type-printing.h +++ b/src/wasm-type-printing.h @@ -48,9 +48,8 @@ template struct TypeNameGeneratorBase { private: constexpr void assertValidUsage() { - // This check current causes a crash on MSVC // TODO: Convert to C++20 requires check -#if !defined(_MSC_VER) && (!defined(__GNUC__) || __GNUC__ >= 14) +#if (!defined(__GNUC__) || __GNUC__ >= 14) // Check that the subclass provides `getNames` with the correct type. using Self = TypeNameGeneratorBase; static_assert( From 90902604d65afcfce10c6fcd523a3d207a48d2db Mon Sep 17 00:00:00 2001 From: Changqing Jing Date: Sat, 16 May 2026 13:15:37 +0800 Subject: [PATCH 2/2] Fix --- src/wasm-type-printing.h | 1 + 1 file changed, 1 insertion(+) diff --git a/src/wasm-type-printing.h b/src/wasm-type-printing.h index e4523de965b..91d4a45e073 100644 --- a/src/wasm-type-printing.h +++ b/src/wasm-type-printing.h @@ -49,6 +49,7 @@ template struct TypeNameGeneratorBase { private: constexpr void assertValidUsage() { // TODO: Convert to C++20 requires check + // The check need MSVC 18.6.0+, otherwise it will cause compiler crash. #if (!defined(__GNUC__) || __GNUC__ >= 14) // Check that the subclass provides `getNames` with the correct type. using Self = TypeNameGeneratorBase;