[wasm] Reset the wasm_eh_prototype flag after unittests
Changing the global state can effect the outcome of later tests. R=jpp@chromium.org Review-Url: https://codereview.chromium.org/2359573003 Cr-Commit-Position: refs/heads/master@{#39595}
This commit is contained in:
parent
b097c6c4f1
commit
d2c975d217
@ -65,12 +65,21 @@ static const WasmOpcode kInt32BinopOpcodes[] = {
|
||||
Verify(kSuccess, sigs.v_i(), code, code + sizeof(code)); \
|
||||
} while (false)
|
||||
|
||||
static bool old_eh_flag;
|
||||
|
||||
class AstDecoderTest : public TestWithZone {
|
||||
public:
|
||||
typedef std::pair<uint32_t, LocalType> LocalsDecl;
|
||||
|
||||
AstDecoderTest() : module(nullptr), local_decls(zone()) {}
|
||||
|
||||
static void SetUpTestCase() { old_eh_flag = FLAG_wasm_eh_prototype; }
|
||||
|
||||
static void TearDownTestCase() {
|
||||
// Reset the wasm_eh_prototype flag
|
||||
FLAG_wasm_eh_prototype = old_eh_flag;
|
||||
}
|
||||
|
||||
TestSignatures sigs;
|
||||
ModuleEnv* module;
|
||||
LocalDeclEncoder local_decls;
|
||||
|
Loading…
Reference in New Issue
Block a user