David Haig
ec41fda58b
Squash
2019-11-28 07:43:53 +00:00
Eduard-Mihai Burtescu
563ed27c01
rustc: move debug info from LocalDecl and UpvarDecl into a dedicated VarDebugInfo.
2019-11-27 19:22:03 +02:00
Matthew Jasper
9abc34ed9d
Track pointers to statics in MIR
2019-11-21 20:55:17 +00:00
Camille GILLOT
ed640c6a27
Merge hir::Mutability into ast::Mutability.
2019-11-10 12:21:05 +01:00
Santiago Pastorino
180fc413fb
Move Place::elem methods and friends to TyCtxt
2019-10-22 10:33:36 -03:00
Santiago Pastorino
d32c2865d6
Intern place projection
2019-10-22 10:33:36 -03:00
Adam Perry
2d5ef8f9ff
Clarify comment about purpose of ReifyShim.
2019-10-11 07:45:59 -07:00
Adam Perry
2dbc62b56a
Clarify shim implementation comment.
2019-10-10 07:50:33 -07:00
Adam Perry
8a097f2619
Clarify comment, dedupe match arms in shim.rs.
...
Also add a missing terminal newline to a test.
2019-10-09 21:02:54 -07:00
Adam Perry
0132738437
Reifying callers of Instance::resolve use resolve_for_fn_ptr.
2019-10-09 20:19:09 -07:00
Adam Perry
012116f860
Add InstanceDef::ReifyShim for track_caller functions.
2019-10-09 20:19:09 -07:00
csmoe
afc0bb9794
clean up GeneratorSubsts
2019-10-04 20:47:43 +08:00
Mazdak Farrokhzad
17e1f23209
Rollup merge of #64817 - csmoe:closure, r=nikomatsakis
...
Replace ClosureSubsts with SubstsRef
Addresses https://github.com/rust-lang/rust/issues/42340 part 3
https://github.com/rust-lang/rust/pull/59312 might benefit from this clean up.
r? @nikomatsakis
2019-10-04 07:24:34 +02:00
csmoe
9b91bef78b
generate ClosureSubsts from SubstsRef
2019-10-03 19:24:59 +08:00
csmoe
64f61c7888
remove indexed_vec re-export from rustc_data_structures
2019-09-29 16:48:31 +00:00
Mark Rousskov
d540d44c71
Remove global_tcx from TyCtxt
...
The non-global context was removed; there's only one context now. This
is a noop method that only serves to confuse readers -- remove it.
2019-09-27 13:33:48 -04:00
varkor
e2e0f9af85
Rename sty
to kind
2019-09-25 15:50:04 +01:00
Santiago Pastorino
87420cd1bc
Make Place Boxed on Statement to reduce size from 64 bytes to 32 bytes
2019-09-11 16:28:06 -03:00
Santiago Pastorino
e9c41148c0
Convert Place's projection to a boxed slice
2019-09-09 18:16:49 -03:00
Wesley Wiser
e63b992030
Resolve PR comments
2019-08-22 06:36:31 -04:00
Wesley Wiser
73814654b2
Move promoted out of mir::Body
2019-08-22 06:36:30 -04:00
bors
a807902dd6
Auto merge of #63463 - matthewjasper:ty_param_cleanup, r=petrochenkov
...
Don't special case the `Self` parameter by name
This results in a couple of small diagnostic regressions. They could be avoided by keeping the special case just for diagnostics, but that seems worse.
closes #50125
cc #60869
2019-08-19 01:31:35 +00:00
Matthew Jasper
24587d20df
Pre intern the Self
parameter type
...
Use this to simplify the object safety code a bit.
2019-08-18 19:25:12 +01:00
Eduard-Mihai Burtescu
b565ece5d8
Remove redundant ty
fields from mir::Constant
and hair::pattern::PatternRange
.
2019-08-16 15:20:27 +03:00
Matthew Jasper
2f6babbc6d
Remove is_self
and has_self_ty
methods
2019-08-11 15:00:42 +01:00
Ralf Jung
8e6fbbec83
add tuple_fields convenience method and use it in a few places
2019-08-11 12:04:49 +02:00
Oliver Scherer
7710820d18
Fiddle param env through to try_eval_bits
in most places
2019-08-05 17:48:05 +02:00
Oliver Scherer
9b87d22ea8
Don't abort on unevaluated constants without at least tryting to eval them
2019-08-05 17:48:04 +02:00
Jeremy Stucki
ec711767a7
Remove needless lifetimes
2019-07-03 10:01:02 +02:00
Santiago Pastorino
099f9e4e8a
Implement From<Local> for Place and PlaceBase
2019-06-25 15:46:23 +02:00
Eduard-Mihai Burtescu
b25b466a88
rustc: remove 'x: 'y bounds (except from comments/strings).
2019-06-18 18:10:21 +03:00
Eduard-Mihai Burtescu
afc39bbf24
Run rustfmt --file-lines ...
for changes from previous commits.
2019-06-14 18:58:32 +03:00
Eduard-Mihai Burtescu
f3f9d6dfd9
Unify all uses of 'gcx and 'tcx.
2019-06-14 18:58:23 +03:00
Eduard-Mihai Burtescu
fff08cb043
Run rustfmt --file-lines ...
for changes from previous commits.
2019-06-12 13:38:28 +03:00
Eduard-Mihai Burtescu
17cdd356da
rustc: replace TyCtxt<'tcx, 'gcx, 'tcx>
with TyCtxt<'gcx, 'tcx>
.
2019-06-12 13:38:27 +03:00
Eduard-Mihai Burtescu
2441253508
Fix fallout from deny(unused_lifetimes)
.
2019-06-12 13:38:27 +03:00
Eduard-Mihai Burtescu
37799a5552
rustc: replace TyCtxt<'a, 'gcx, 'tcx>
with TyCtxt<'tcx, 'gcx, 'tcx>
.
2019-06-12 13:38:27 +03:00
Jad Ghalayini
80ff07f30d
Changed usages of mir
in librustc::mir and librustc_mir to body
2019-06-09 16:05:05 -04:00
Matthew Jasper
6c9a018b60
Don't run MIR passes on constructor shims
2019-06-06 16:10:37 +01:00
John Kåre Alsaker
6d387463aa
Remove GlobalArenas and use Arena instead
2019-05-31 09:44:37 +02:00
Claude-Alban RANÉLY-VERGÉ-DÉPRÉ
6e5e0daff2
Changes the type mir::Mir
into mir::Body
...
The commit should have changed comments as well.
At the time of writting, it passes the tidy and check tool.
Revisions asked by eddyb :
- Renamed of all the occurences of {visit/super}_mir
- Renamed test structures `CachedMir` to `Cached`
Fixing the missing import on `AggregateKind`
2019-05-28 19:17:51 +02:00
Andrew Xu
46b9ed4fa1
Rename "Associated*" to "Assoc*"
...
We are going to uniform the terminology of all associated items.
Methods that may or may not have `self` are called "associated
functions". Because `AssociatedFn` is a bit long, we rename `Associated`
to `Assoc`.
2019-05-26 17:49:02 +08:00
Oliver Scherer
e694b63cd1
Don't use ty::Const
without immediately interning
2019-05-25 10:07:01 +02:00
Nicholas Nethercote
b557567c35
Remove impls for InternedString
/string equality.
...
`Symbol` received the same treatment in #60630 .
Also, we can derive `PartialEq` for `InternedString`.
2019-05-21 20:08:33 +10:00
bors
47e0803d5c
Auto merge of #60195 - varkor:commontypes-to-common, r=eddyb
...
Split `CommonTypes` into `CommonTypes` and `CommonLifetimes`
The so-called "`CommonTypes`" contains more than just types.
r? @eddyb
2019-05-01 09:32:58 +00:00
flip1995
e1da67e69c
Fix lint findings in librustc_mir
2019-04-28 21:19:27 +02:00
varkor
a3470c6189
Update handling of Tuple
2019-04-26 21:09:32 +01:00
varkor
7261bd88ac
Update existing usages
2019-04-25 22:05:04 +01:00
David Wood
5c3d1e5d76
Separate variant id and variant constructor id.
...
This commit makes two changes - separating the `NodeId` that identifies
an enum variant from the `NodeId` that identifies the variant's
constructor; and no longer creating a `NodeId` for `Struct`-style enum
variants and structs.
Separation of the variant id and variant constructor id will allow the
rest of RFC 2008 to be implemented by lowering the visibility of the
variant's constructor without lowering the visbility of the variant
itself.
No longer creating a `NodeId` for `Struct`-style enum variants and
structs mostly simplifies logic as previously this `NodeId` wasn't used.
There were various cases where the `NodeId` wouldn't be used unless
there was an unit or tuple struct or enum variant but not all uses of
this `NodeId` had that condition, by removing this `NodeId`, this must
be explicitly dealt with. This change mostly applied cleanly, but there
were one or two cases in name resolution and one case in type check
where the existing logic required a id for `Struct`-style enum variants
and structs.
2019-03-24 12:10:16 +03:00
Oliver Scherer
5cd2806621
Revert the LazyConst
PR
2019-03-16 21:04:10 +01:00