TypeScript/tests/baselines/reference/computedPropertyNames35.errors.txt

14 lines
762 B
Text
Raw Normal View History

tests/cases/conformance/es6/computedProperties/computedPropertyNames35.ts(4,5): error TS1169: Computed property names are not allowed in interfaces.
2015-01-22 00:05:19 +01:00
tests/cases/conformance/es6/computedProperties/computedPropertyNames35.ts(4,10): error TS2466: A computed property name cannot reference a type parameter from its containing type.
==== tests/cases/conformance/es6/computedProperties/computedPropertyNames35.ts (2 errors) ====
function foo<T>() { return '' }
interface I<T> {
bar(): string;
[foo<T>()](): void;
~~~~~~~~~~
!!! error TS1169: Computed property names are not allowed in interfaces.
~
2015-01-22 00:05:19 +01:00
!!! error TS2466: A computed property name cannot reference a type parameter from its containing type.
}