diff --git a/src/wasm/wasm-module-builder.cc b/src/wasm/wasm-module-builder.cc index 901c306b9b..7b8d5639c1 100644 --- a/src/wasm/wasm-module-builder.cc +++ b/src/wasm/wasm-module-builder.cc @@ -306,7 +306,7 @@ void WasmModuleBuilder::MarkStartFunction(WasmFunctionBuilder* function) { void WasmModuleBuilder::AddExport(Vector name, WasmFunctionBuilder* function) { - DCHECK(function->func_index() <= std::numeric_limits::max()); + DCHECK_LE(function->func_index(), std::numeric_limits::max()); function_exports_.push_back({name, static_cast(function->func_index())}); }