diff --git a/js/src/vm/StringType.h b/js/src/vm/StringType.h index 38dea85c6069..963e77c8ea6a 100644 --- a/js/src/vm/StringType.h +++ b/js/src/vm/StringType.h @@ -1737,7 +1737,9 @@ inline JSLinearString* NewStringCopy( } /* Copy a counted string and GC-allocate a descriptor for it. */ -template +template < + js::AllowGC allowGC, typename CharT, + typename std::enable_if_t>* = nullptr> inline JSLinearString* NewStringCopy( JSContext* cx, std::basic_string_view s, js::gc::Heap heap = js::gc::Heap::Default) {