Files
tsgo/testdata/baselines/reference/submodule/compiler/checkForObjectTooStrict(target=es2015).errors.txt
2026-04-15 00:09:01 +00:00

37 lines
720 B
Plaintext

checkForObjectTooStrict.ts(3,18): error TS2725: Class name cannot be 'Object' when targeting ES5 and above with module CommonJS.
==== checkForObjectTooStrict.ts (1 errors) ====
namespace Foo {
export class Object {
~~~~~~
!!! error TS2725: Class name cannot be 'Object' when targeting ES5 and above with module CommonJS.
}
}
class Bar extends Foo.Object { // should work
constructor () {
super();
}
}
class Baz extends Object {
constructor () { // ERROR, as expected
super();
}
}