File tree Expand file tree Collapse file tree 2 files changed +7
-3
lines changed Expand file tree Collapse file tree 2 files changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -504,8 +504,15 @@ func (ts *Typescript) parse(obj types.Object) error {
504504 })
505505 }
506506
507+ if underNamed .NumEmbeddeds () == 0 && underNamed .NumMethods () > 0 {
508+ // type <Name> interface{ <methods> }
509+ // Do not generate anything for interfaces.
510+ return nil
511+ }
512+
507513 if underNamed .NumEmbeddeds () == 0 {
508514 // type <Name> interface{}
515+ // A typed `any` is still a type. A strange one to use, but still valid.
509516 // TODO: This has not been fully investigated. This line should only be triggered
510517 // on simple `any` types. If this generates something more complex, this will be wrong.
511518 ts .updateNode (objectIdentifier .Ref (), func (n * typescriptNode ) {
Original file line number Diff line number Diff line change @@ -16,6 +16,3 @@ export interface Foo extends Bar, GenBar<string> {
1616export interface GenBar < T extends Comparable > {
1717 readonly GenBarField : T ;
1818}
19-
20- // From codersdk/interface.go
21- export type IgnoreMe = any ;
You can’t perform that action at this time.
0 commit comments