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

disable nested struct for array and map type #4222

Merged
merged 1 commit into from
Jun 29, 2024

Conversation

kesonan
Copy link
Collaborator

@kesonan kesonan commented Jun 29, 2024

  1. disable nested struct for array and map type, the follow types all are invalid:
type Demo {
  Foo {} `json:"foo"` // invalid types: unsupported empty nestedt struct
  Bar []{} `json:"foo"` // invalid types: slice elements unsupported nested struct
  Bar [2]{} `json:"foo"` // invalid types: array elements unsupported nested struct
  Bar map[{}]string `json:"foo"` // invalid types: map key elements unsupported nested struct
  Bar map[int]{} `json:"foo"` // invalid types: map value elements unsupported nested struct
}

@kesonan kesonan requested a review from kevwan June 29, 2024 04:15
Copy link

codecov bot commented Jun 29, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 95.09%. Comparing base (8690859) to head (f858c87).
Report is 71 commits behind head on master.

Additional details and impacted files

see 255 files with indirect coverage changes

@kevwan kevwan added this pull request to the merge queue Jun 29, 2024
Merged via the queue into zeromicro:master with commit 2f9b6cf Jun 29, 2024
6 checks passed
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.

None yet

2 participants