Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
skip_type_params
attribute #96Add
skip_type_params
attribute #96Changes from 12 commits
39ee6b4
b0eda68
bd6dd5d
171cd4c
030d407
b937c9a
725ceca
56edb9c
f503781
1743b48
bf9cf6d
2d4f1e8
9c4f6d6
100dfcf
c92041b
a23cd47
3678114
4cdf0c5
99cb9d3
c39167d
835efe3
75d25ad
3012932
20ff837
7cdd440
6d97c49
7cab3e3
1f84f41
0716333
a2d239b
ecf21f3
f876d22
b58904f
9f64f74
d61f75d
a1741d2
2da8e3f
2dc9484
39e40b1
44c2af2
91799c7
e4d570d
271c2b5
a7e1e6b
411e50c
c5f2bd1
d453e69
b228318
f060e59
7bfa773
eb41e0b
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it seems to me more correct to me to have the first type param marked as
skipped
than ignored, otherwise when looking at the metadata and the doc of the rust type we can't easily tell which one is skipped and which one is keptThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You mean like
.composite(Fields::named().field(|f| f.ty::<Greet<SomeType>>().name("ciao").type_name("Greet<T>").skipped_type_params::<T>())
?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
actually I'm not sure anymore, I don't understand enough the usecase for type_params.
But what I meant is that currently the
Hey<SomeType, u16>
type information about type params would beu16
, whereas I would have expected"skipped", u16
.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a good point, we are losing some information by removing it entirely. I have addressed this by adding a
TypeParameter
struct withOption<MetaType>
which would beNone
for skipped type params. Addressed in 411e50c