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

23 lines
1.2 KiB
Plaintext
Raw Normal View History

tests/cases/compiler/parameterPropertyInConstructor2.ts(3,5): error TS2394: Overload signature is not compatible with function implementation.
tests/cases/compiler/parameterPropertyInConstructor2.ts(3,17): error TS2369: A parameter property is only allowed in a constructor implementation.
2014-10-01 02:15:18 +02:00
tests/cases/compiler/parameterPropertyInConstructor2.ts(3,24): error TS2300: Duplicate identifier 'names'.
2014-10-01 20:27:20 +02:00
tests/cases/compiler/parameterPropertyInConstructor2.ts(4,24): error TS2300: Duplicate identifier 'names'.
2014-10-01 02:15:18 +02:00
==== tests/cases/compiler/parameterPropertyInConstructor2.ts (4 errors) ====
2014-07-13 01:04:16 +02:00
module mod {
class Customers {
constructor(public names: string);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
!!! error TS2394: Overload signature is not compatible with function implementation.
2014-07-13 01:04:16 +02:00
~~~~~~~~~~~~~~~~~~~~
!!! error TS2369: A parameter property is only allowed in a constructor implementation.
2014-07-13 01:04:16 +02:00
~~~~~
2014-10-01 02:15:18 +02:00
!!! error TS2300: Duplicate identifier 'names'.
constructor(public names: string, public ages: number) {
2014-10-01 20:27:20 +02:00
~~~~~
!!! error TS2300: Duplicate identifier 'names'.
2014-07-13 01:04:16 +02:00
}
}
}