-
Notifications
You must be signed in to change notification settings - Fork 161
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
Required features for Rust For Linux #3309
base: master
Are you sure you want to change the base?
Conversation
37984d9
to
23df30c
Compare
* ast/rust-ast-visitor.cc (DefaultASTVisitor::visit): enabled a default visitor to be overrided * ast/rust-ast-visitor.h: passes a method virtual * checks/errors/rust-feature-gate.cc (FeatureGate::visit): implements all checks for the new features * checks/errors/rust-feature-gate.h: the prototypes of the new checkers * checks/errors/rust-feature.cc (Feature::create): implements the recognition and creation of some new features * checks/errors/rust-feature.h: creation of the features name in the enum gcc/testsuite/ChangeLog: * rust/compile/feature_extern_types.rs: Move to... * rust/compile/features/extern_types.rs: ...here. * rust/compile/feature_intrinsics.rs: Move to... * rust/compile/features/intrinsics.rs: ...here. * rust/compile/features/arbitrary_self_types_activated.rs: New test. * rust/compile/features/arbitrary_self_types_not_activated.rs: New test. * rust/compile/features/associated_type_defaults_activated.rs: New test. * rust/compile/features/const_trait_impl_activated.rs: New test. * rust/compile/features/doc_cfg_activated.rs: New test. * rust/compile/features/doc_cfg_not_activated.rs: New test. * rust/compile/features/feature.exp: New test. * rust/compile/features/impl_trait_in_assoc_type_activated.rs: New test. * rust/compile/features/impl_trait_in_assoc_type_not_activated.rs: New test. * rust/compile/features/register_tool_activated.rs: New test. * rust/compile/features/register_tool_not_activated.rs: New test.
23df30c
to
be4b230
Compare
As for now, all features marked as "Required" in #3210 are recognized, except |
* checks/errors/rust-feature-gate.cc (FeatureGate::visit): cleaning file. * checks/errors/rust-feature-gate.h: cleaning file. * checks/errors/rust-feature.cc: cleaning file. gcc/testsuite/ChangeLog: * rust/compile/features/associated_type_defaults_activated.rs: Changed test to code that used the tested feature. * rust/compile/features/associated_type_defaults_not_activated.rs: New test. Will be failing, but dg-error not set up yet. Signed-off-by: lucas.plantrose <[email protected]>
be4b230
to
a9e2683
Compare
#include "rust-path.h" | ||
#include "rust-type.h" | ||
#include "rust-tyty.h" | ||
#include <iostream> |
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 should use rust-system.h i dont see why you need iostream and rust-tyty.h for the type abstractions
@@ -435,7 +435,7 @@ class DefaultASTVisitor : public ASTVisitor | |||
virtual void visit (AST::StructPatternElements &spe); | |||
virtual void visit (AST::MaybeNamedParam ¶m); | |||
|
|||
void visit (AST::Attribute &attribute) {} | |||
virtual void visit (AST::Attribute &attribute) {} |
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.
does this need virtual i dont see where your overriding it
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.
oh wait scratch that i see now sorry
Fixes #3233.
This PR is here to show the work done on the recognition of the required features for Rust for Linux mentioned in the #3210, and aims to implement all of them.