TypeScript Version: 2.7.1
Search Terms: trailing comma template literal types generic
Code
class FooClass<
A,
B,
C,
> {
a: A;
b: B;
c: C;
}
const instance = new FooClass<
boolean,
number,
string, // [ts] Trailing comma not allowed.
>();
Expected behavior:
No errors as of #16152's resolution.
Actual behavior:
Trailing comma not allowed.
Playground Link: http://www.typescriptlang.org/play/#src=class%20FooClass%3C%0D%0A%09A%2C%0D%0A%09B%2C%0D%0A%09C%2C%0D%0A%3E%20%7B%0D%0A%09a%3A%20A%3B%0D%0A%09b%3A%20B%3B%0D%0A%09c%3A%20C%3B%0D%0A%7D%0D%0A%0D%0Aconst%20instance%20%3D%20new%20FooClass%3C%0D%0A%09boolean%2C%0D%0A%09number%2C%0D%0A%09string%2C%20%2F%2F%20%5Bts%5D%20Trailing%20comma%20not%20allowed.%0D%0A%09%3E()%3B
Related Issues:
#16152. @samal84 mentioned something like this but I couldn't parse what they meant without a code sample (is this it?). I'll take I can, if this is approved, take a stab at removing this error too.
TypeScript Version: 2.7.1
Search Terms: trailing comma template literal types generic
Code
Expected behavior:
No errors as of #16152's resolution.
Actual behavior:
Trailing comma not allowed.Playground Link: http://www.typescriptlang.org/play/#src=class%20FooClass%3C%0D%0A%09A%2C%0D%0A%09B%2C%0D%0A%09C%2C%0D%0A%3E%20%7B%0D%0A%09a%3A%20A%3B%0D%0A%09b%3A%20B%3B%0D%0A%09c%3A%20C%3B%0D%0A%7D%0D%0A%0D%0Aconst%20instance%20%3D%20new%20FooClass%3C%0D%0A%09boolean%2C%0D%0A%09number%2C%0D%0A%09string%2C%20%2F%2F%20%5Bts%5D%20Trailing%20comma%20not%20allowed.%0D%0A%09%3E()%3B
Related Issues:
#16152. @samal84 mentioned something like this but I couldn't parse what they meant without a code sample (is this it?).
I'll takeI can, if this is approved, take a stab at removing this error too.