| Age | Commit message (Collapse) | Author | Lines |
|
|
|
|
|
|
|
I needed it in `RawVec`, `Vec`, and `TypedArena` for `rustc` to
bootstrap; but of course that alone was not sufficient for `make
check`.
Later I added `unsafe_destructor_blind_to_params` to collections, in
particular `LinkedList` and `RawTable` (the backing representation for
`HashMap` and `HashSet`), to get the regression tests exercising
cyclic structure from PR #27185 building.
----
Note that the feature is `dropck_parametricity` (which is not the same
as the attribute's name). We will almost certainly vary our strategy
here in the future, so it makes some sense to have a not-as-ugly name
for the feature gate. (The attribute name was deliberately selected to
be ugly looking.)
|
|
Implement cannot-assume-parametricity (CAP) from RFC 1238, and add the
UGEH attribute.
----
Note that we check for the attribute attached to the dtor method, not
the Drop impl.
(This is just to match the specification of RFC and the tests; I am
not wedded to this approach.)
|
|
|
|
|
|
|
|
Fix #28402.
|
|
|
|
|
|
|
|
|
|
paths, and construct paths for all definitions. Also, stop rewriting
DefIds for closures, and instead just load the closure data from
the original def-id, which may be in another crate.
|
|
This enables the Debug trait to work on syntax::ast::Stmt.
|
|
|
|
|
|
+ Add helper macro for walking lists (including Options)
|
|
This PR removes random remaining `Ident`s outside of libsyntax and performs general cleanup
In particular, interfaces of `Name` and `Ident` are tidied up, `Name`s and `Ident`s being small `Copy` aggregates are always passed to functions by value, and `Ident`s are never used as keys in maps, because `Ident` comparisons are tricky.
Although this PR closes https://github.com/rust-lang/rust/issues/6993 there's still work related to it:
- `Name` can be made `NonZero` to compress numerous `Option<Name>`s and `Option<Ident>`s but it requires const unsafe functions.
- Implementation of `PartialEq` on `Ident` should be eliminated and replaced with explicit hygienic, non-hygienic or member-wise comparisons.
- Finally, large parts of AST can potentially be converted to `Name`s in the same way as HIR to clearly separate identifiers used in hygienic and non-hygienic contexts.
r? @nrc
|
|
This adds a new target property, `target_vendor`. It is to be be used as a matcher for conditional compilation. The vendor is part of the [autoconf target triple](http://llvm.org/docs/doxygen/html/classllvm_1_1Triple.html#details): `<arch><sub>-<vendor>-<os>-<env>`. `arch`, `target_os` and `target_env` are already supported by Rust.
This change was suggested in PR #28593. It enables conditional compilation based on the vendor. This is needed for the rumprun target, which needs to match against both, target_os and target_vendor.
The default value for `target_vendor` is "unknown", "apple" and "pc" are other common values.
Matching against the `target_vendor` is introduced behind the feature gate `#![feature(cfg_target_vendor)]`.
This is the first time I messed around with rustc internals. I just added the my code where I found the existing `target_*` variables, hopefully I haven't missed anything. Please review with care. :)
r? @alexcrichton
|
|
Make sure Name, SyntaxContext and Ident are passed by value
Make sure Idents don't serve as keys (or parts of keys) in maps, Ident comparison is not well defined
|
|
|
|
This adds a new target property, `target_vendor` which can be used as a
matcher for conditional compilation. The vendor is part of the autoconf
target triple: <arch><sub>-<vendor>-<os>-<env>
The default value for `target_vendor` is "unknown".
Matching against the `target_vendor` with `#[cfg]` is currently feature
gated as `cfg_target_vendor`.
|
|
|
|
Closes https://github.com/rust-lang/rust/issues/28075
Closes https://github.com/rust-lang/rust/issues/28388
r? @eddyb
cc @brson
|
|
This enables the Debug trait to work on syntax::ast::Stmt
|
|
|
|
Closes #28527.
r? @Manishearth
|
|
Fixes https://github.com/rust-lang/rust/issues/28520.
r? @alexcrichton or @nrc?
|
|
Closes #28527.
|
|
|
|
- Successful merges: #28463, #28507, #28522, #28525, #28526
- Failed merges:
|
|
This reduces some clones of `Vec`s. These are not deep copies since the
token tree is made using `Rc`s, so this won't be a major improvement.
r? @eddyb
|
|
Fixes https://github.com/rust-lang/rust/issues/28472.
|
|
|
|
Closes #28091.
|
|
Implements overload-able augmented/compound assignments, like `a += b` via the `AddAssign` trait, as specified in RFC [953]
[953]: https://github.com/rust-lang/rfcs/blob/master/text/0953-op-assign.md
r? @nikomatsakis
|
|
Temporary 'fix' for #26775
r? @brson
|
|
|
|
|
|
Followup on #28440
Do not merge before the referenced PR is merged. I will fix the PR once that is merged (or close if it is not)
|
|
|
|
|
|
Temporary 'fix' for #26775
|
|
|
|
|
|
|
|
Followup on #28440
|
|
fixes #28433
|
|
|