Skip to content

Instantiation params of generic functions don't get prefixed with the package nameΒ #95

@rflect-ch

Description

@rflect-ch

If I try to wrap a gRPC server which is generated with generic types, instantiation params on the generic types are not prefixed with package in the wrapper.

Provisional example:

type BadgesServer interface {
       Subscribe(*SubscribeRequest, grpc.ServerStreamingServer[BadgeEvent]) error
}

BadgeEvent is a proto message defined in the same package as the BadgeServer.

In this case gowrap will generate wrapper where BadgeEvent will not be prefixed with its package but will just stay as BadgeEvent. This way it reports an error because as expected the target package doesn't have the type defined.

I have fixed it by disabling generic code generation in protos, but would be nice to have support for this properly in gowrap.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions