Skip to content
New issue

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

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

Already on GitHub? # to your account

fix(schema/gen): return value not reference #38

Merged
merged 1 commit into from
Nov 13, 2019

Conversation

hannahhoward
Copy link
Collaborator

Map/List should return an actual node type, not a pointer to a node. Otherwise, breaks when nested
in other map/list type.

We use a pointer to a node when we're building nodes, for maps (so we can mod it easily I assume). However, when we actually build it, we should dereference it -- because that's the type anyone using the node expects-- and in fact things will error if you build a map inside a map.

Map/List should return an actual node type, not a pointer to a node. Otherwise, breaks when nested
in other map/list type
@codecov
Copy link

codecov bot commented Nov 7, 2019

Codecov Report

Merging #38 into master will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master      #38   +/-   ##
=======================================
  Coverage   72.42%   72.42%           
=======================================
  Files          50       50           
  Lines        3154     3154           
=======================================
  Hits         2284     2284           
  Misses        780      780           
  Partials       90       90
Impacted Files Coverage Δ
schema/gen/go/genKindStructNode.go 99.04% <100%> (ø) ⬆️
schema/gen/go/genKindListNode.go 100% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 8dff1cb...02b9c8d. Read the comment docs.

@warpfork
Copy link
Collaborator

Good eye. I'm mildly surprised this even compiled...

@warpfork warpfork merged commit 8735bb1 into master Nov 13, 2019
@warpfork warpfork deleted the fix/return_value_not_reference branch November 13, 2019 09:45
@aschmahmann aschmahmann mentioned this pull request Sep 22, 2020
72 tasks
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants