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

feat: add support for named primitive types #67

Merged
merged 5 commits into from
Aug 28, 2024

Conversation

yassinebenaid
Copy link
Owner

This PR adds support for named primitive types.

Before now:

...

type X string

v := X("foo")

godump.Dump(v)

godump.Dump("bar")

would result in:

"foo"
"Bar"

Now :

pkg.X("foo")

"Bar"

This change comes after me having a hard time while using this library in a project in which we have large data-structures with named primitives.

Copy link

codecov bot commented Aug 26, 2024

Codecov Report

Attention: Patch coverage is 90.47619% with 2 lines in your changes missing coverage. Please review.

Project coverage is 97.87%. Comparing base (3378832) to head (1bd0468).

Files Patch % Lines
dumper.go 90.47% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master      #67      +/-   ##
==========================================
- Coverage   98.87%   97.87%   -1.00%     
==========================================
  Files           1        1              
  Lines         177      188      +11     
==========================================
+ Hits          175      184       +9     
- Misses          2        3       +1     
- Partials        0        1       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

testdata/primitives.txt Outdated Show resolved Hide resolved
@ccoVeille
Copy link
Collaborator

Also please fix typo: primitive not pimitive

In the commit message and the PR title

@yassinebenaid yassinebenaid changed the title chore: added pimitive type feat: add support for named primitive types Aug 27, 2024
ccoVeille
ccoVeille previously approved these changes Aug 27, 2024
@yassinebenaid yassinebenaid merged commit 9ec8fce into master Aug 28, 2024
2 checks passed
@yassinebenaid yassinebenaid deleted the add-primitive-types branch August 28, 2024 08:30
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