If a struct's type parameter is only used in a PhantomData field, it is missing from the generated .d.ts.
To reproduce
Clone this repo and follow the steps in README.md, which generates:
/* tslint:disable */
/* eslint-disable */
export interface Foo {}
... from:
pub struct Foo<T> {
bar: PhantomData<T>,
}
Expected behaviour
Either of the following should be generated:
-
/* tslint:disable */
/* eslint-disable */
export interface Foo<T> {}
-
/* tslint:disable */
/* eslint-disable */
export interface Foo<_> {}
If a struct's type parameter is only used in a
PhantomDatafield, it is missing from the generated.d.ts.To reproduce
Clone this repo and follow the steps in
README.md, which generates:... from:
Expected behaviour
Either of the following should be generated: