Mike Pennisi 81d00def42 Force "early error" tests to fail if evaluated
This pattern makes expectations more explicit by making test files more
literal.
2017-06-28 11:24:36 -04:00

16 lines
367 B
JavaScript

// Copyright 2009 the Sputnik authors. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
/*---
info: The "this" is reserved word
es5id: 11.1.1_A1
description: Checking if execution of "this=1" fails
negative:
phase: early
type: ReferenceError
---*/
throw "Test262: This statement should not be evaluated.";
this = 1;