downlevel-dts icon indicating copy to clipboard operation
downlevel-dts copied to clipboard

[bug] type parameter names are stripped erroneously leading to broken code

Open bradzacher opened this issue 2 years ago • 3 comments

Input:

declare abstract class DefinitionBase<TType extends string> {}

Expected:

declare abstract class DefinitionBase<TType extends string> {}

Actual:

declare abstract class DefinitionBase< extends string> {}

bradzacher avatar May 10 '22 02:05 bradzacher

This appears to be a regression in 0.10.0 and does not happen in 0.9.0

antoniosZ avatar May 10 '22 14:05 antoniosZ

Bug seems to be still present in v 0.11.0

Sample input and output: repro.zip

Target used: 4.2

michkot avatar Nov 24 '22 02:11 michkot

combination of TS 4.9.3 and this 0.11.0 seems to work correctly - I assume one must always pair "correct" TS and downlevel-dts versions (although its not entirely clear to me what the "correct" version is for the past releases)

michkot avatar Dec 01 '22 19:12 michkot