Skip to content

[RemoteAST/Reflection] Changes to MetadataReader and its users to track function parameter flags #12421

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

Merged
merged 4 commits into from
Oct 17, 2017

Conversation

xedin
Copy link
Contributor

@xedin xedin commented Oct 13, 2017

No description provided.

@xedin xedin changed the title [RemoteAST/Reflection] Changes to MetadataReader and its users to track function parameter flags [WIP] [RemoteAST/Reflection] Changes to MetadataReader and its users to track function parameter flags Oct 13, 2017
BuiltType Type;
StringRef Label;

union {
Copy link
Member

Choose a reason for hiding this comment

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

This shouldn't be a union.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ah, sorry, I wanted to change that to be to enum like other flags we have...

if (auto ArgumentTypeRef = readTypeFromMetadata(FlaggedArgumentAddress))
Arguments.push_back(ArgumentTypeRef);
else
FlaggedArgumentAddress &= ~InOutMask;
Copy link
Member

Choose a reason for hiding this comment

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

shared and variadic, too? It's odd to have them partially-supported, so I suggest either completing support or leaving a FIXME to do it all later.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, that's the next step after MetadataReader is updated to support these flags I'm going to update function metadata itself to include all of the flags for parameters...

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Added a FIXME about it on L807, going to address after this changes are in.

@xedin xedin force-pushed the metadata-reader-fn-flags branch from 2b0c7bb to 6dd6d01 Compare October 13, 2017 21:55
template <typename BuiltType> class FunctionParam {
BuiltType Type;
StringRef Label;
ParameterTypeFlags Flags;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@DougGregor please let me know what you think about this? I'm not sure if it's comme il faut to use structures from AST/Types.h in here.

@xedin xedin force-pushed the metadata-reader-fn-flags branch from 9831b69 to af7f1ea Compare October 14, 2017 00:57
@xedin
Copy link
Contributor Author

xedin commented Oct 14, 2017

@swift-ci please clean test

@swiftlang swiftlang deleted a comment from swift-ci Oct 14, 2017
@swiftlang swiftlang deleted a comment from swift-ci Oct 14, 2017
@xedin
Copy link
Contributor Author

xedin commented Oct 15, 2017

@slavapestov it looks like I should be bugging you about changes to Reflection/RemoteAST instead :)

@xedin xedin requested a review from slavapestov October 15, 2017 01:29
@xedin xedin changed the title [WIP] [RemoteAST/Reflection] Changes to MetadataReader and its users to track function parameter flags [RemoteAST/Reflection] Changes to MetadataReader and its users to track function parameter flags Oct 15, 2017
@xedin xedin force-pushed the metadata-reader-fn-flags branch from af7f1ea to c9d70dc Compare October 17, 2017 00:24
@xedin
Copy link
Contributor Author

xedin commented Oct 17, 2017

@swift-ci please clean test

@swiftlang swiftlang deleted a comment from swift-ci Oct 17, 2017
@swiftlang swiftlang deleted a comment from swift-ci Oct 17, 2017
@xedin xedin merged commit e0a97ed into swiftlang:master Oct 17, 2017
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