Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add doc string for WKT scalars #75

Merged
merged 2 commits into from
Sep 25, 2023
Merged

Add doc string for WKT scalars #75

merged 2 commits into from
Sep 25, 2023

Conversation

emcfarlane
Copy link
Collaborator

No description provided.

@emcfarlane emcfarlane requested a review from jhump September 25, 2023 16:48
@emcfarlane emcfarlane self-assigned this Sep 25, 2023
params.go Outdated
func isScalarWKT(field protoreflect.FieldDescriptor) bool {
return field.Kind() == protoreflect.MessageKind &&
isScalarWellKnownType[field.Message().FullName()]
// isScalarWellKnownType returns true if the field is a well-known type that is
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should come up with more clear naming for this function. Without reading the whole comment, this still reads to me as "return true if the given type is a scalar WKT", of which of course none of the WKTs are. Perhaps a cleaned up version of "isWKTWithScalarJSONMapping" is more appropriate.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Moved to isWKTWithScalarJSONMapping and ignoring goconst.

@emcfarlane emcfarlane merged commit 3ee82c3 into main Sep 25, 2023
@emcfarlane emcfarlane deleted the ed/wktdocs branch September 25, 2023 19:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants