Niko Matsakis
2655522580
move type_op
into rustc
2018-06-26 10:59:40 -04:00
Niko Matsakis
3b446b4b91
introduce QueryTypeOp
trait and use it for eq
2018-06-26 10:59:40 -04:00
Niko Matsakis
1d664622b6
remove Canonicalization
trait, which serves no purpose
2018-06-26 10:59:38 -04:00
Zack M. Davis
64365e46f2
driveby status update to 2015 comment about parens in patterns
2018-06-26 07:54:49 -07:00
Zack M. Davis
3fb76f4027
inclusive range syntax lint (...
→ ..=
)
...
Our implementation ends up changing the `PatKind::Range` variant in the
AST to take a `Spanned<RangeEnd>` instead of just a `RangeEnd`, because
the alternative would be to try to infer the span of the range operator
from the spans of the start and end subexpressions, which is both
hideous and nontrivial to get right (whereas getting the change to the
AST right was a simple game of type tennis).
This is concerning #51043 .
2018-06-26 07:54:49 -07:00
Zack M. Davis
057715557b
migrate codebase to ..=
inclusive range patterns
...
These were stabilized in March 2018's #47813 , and are the Preferred Way
to Do It going forward (q.v. #51043 ).
2018-06-26 07:53:30 -07:00
Niko Matsakis
d748dc5db0
extract query_result_substitution
helper
2018-06-26 10:51:10 -04:00
Niko Matsakis
75e3a9c8fd
rename instantiate_query_result
2018-06-26 10:51:08 -04:00
Niko Matsakis
e72dc79488
make convert
so it can apply to a single constraint
2018-06-26 10:49:24 -04:00
Niko Matsakis
3f1961d62e
extract type-ops into their own submodules
2018-06-26 10:49:24 -04:00
Niko Matsakis
7cb86ed1e3
change to crate
privacy instead of pub(super)
2018-06-26 10:49:24 -04:00
Niko Matsakis
21592cdecd
move Debug
bounds onto Lift
...
Just for convenience.
2018-06-26 10:49:24 -04:00
Niko Matsakis
be27a5a775
make one Canonicalize
impl for QueryResult
...
This lets us simplify a few type aliases.
2018-06-26 10:49:24 -04:00
Niko Matsakis
7358931a1c
improve trivial_case
handling
2018-06-26 10:49:24 -04:00
Niko Matsakis
c8cf710ce0
replace LexicalRegionConstraintData
with QueryRegionConstraint
2018-06-26 10:49:24 -04:00
Niko Matsakis
2624c14a26
extract the handling of region constraints from queries
2018-06-26 10:49:24 -04:00
Niko Matsakis
bebd3ff666
extract a helper for make_query_result
that skips canonicalization
2018-06-26 10:49:24 -04:00
Niko Matsakis
dfd33f5932
move make_query_response
into method on infcx
2018-06-26 10:49:24 -04:00
Niko Matsakis
a1811cef76
break canonicalizer into submodules to make it easier to comprehend
2018-06-26 10:49:23 -04:00
Josef Reinhard Brandl
1f9aa1332f
Split libcore/task.rs into submodules
2018-06-26 16:40:42 +02:00
Oliver Schneider
28a76a9000
Don't inspect the generated existential type items
2018-06-26 16:36:32 +02:00
Niko Matsakis
5e9f8d5c69
promote canonical into a module
2018-06-26 10:31:49 -04:00
Niko Matsakis
71234278fa
align the type-op
outputs with what canonicalized queries give
2018-06-26 10:31:49 -04:00
Niko Matsakis
6ac89174b8
mk fully_perform_op_and_get_region_constraint_data
a TypeOp method
2018-06-26 10:31:49 -04:00
Niko Matsakis
efc84c83f9
remove the TypeOp
vs InfcxTypeOp
distinction
2018-06-26 10:31:49 -04:00
Niko Matsakis
dee18864ad
promote type_op
into a mod.rs
file
2018-06-26 10:31:49 -04:00
Niko Matsakis
252a6dfa35
introduce DropckOutlives
type-op
2018-06-26 10:31:49 -04:00
Niko Matsakis
7a641cb145
make TypeOp
implement debug instead of carrying a closure
...
This allows us to avoid some silly clones etc.
2018-06-26 10:31:49 -04:00
Niko Matsakis
e7a9e7aef2
extract a enabled
helper to remove some ad-hoc conditionals
2018-06-26 10:31:49 -04:00
Niko Matsakis
65ceec71ec
make TypeOutlives
parameterized over a delegate
...
It was only using the `infcx` to "accumulate" constraints anyhow.
2018-06-26 10:31:49 -04:00
Niko Matsakis
b858ed5919
obligations.rs: rustfmt
2018-06-26 10:31:49 -04:00
Niko Matsakis
5829746ddd
resolve type vars *before* entering type_must_outlive
...
All recursive calls only use type-vars that should already be
resolved, because they were obtained from `ty`.
2018-06-26 10:31:49 -04:00
Niko Matsakis
13e77934e5
create InfcxTypeOp
that only depend on an infcx
...
We want any add'l context required to be passed through the struct
itself.
2018-06-26 10:31:49 -04:00
Niko Matsakis
846cc263cf
make normalize into an op
2018-06-26 10:31:49 -04:00
Niko Matsakis
f998628e5c
let trivial_noop
take ownership of self
2018-06-26 10:31:49 -04:00
Niko Matsakis
8147d17d8e
make normalize
take ownership of the thing to be normalized
2018-06-26 10:31:49 -04:00
Niko Matsakis
214d7650c9
introduce prove_predicates
type op
2018-06-26 10:31:49 -04:00
Niko Matsakis
7c62461c39
introduce trivial_noop
to accommodate micro-optimizations
2018-06-26 10:31:49 -04:00
Niko Matsakis
9b4fe44280
introduce Eq
type-op
2018-06-26 10:31:49 -04:00
Niko Matsakis
2b52793f74
introduce Subtype
type_op
2018-06-26 10:31:49 -04:00
Niko Matsakis
909b10c33b
introduce type_op
2018-06-26 10:31:49 -04:00
bors
2808460e0f
Auto merge of #51678 - Zoxc:combine-lints, r=estebank
...
Combine all builtin late lints
2018-06-26 14:18:13 +00:00
Oliver Schneider
a693c9206b
Use proper debugging statements for infinite recursion assertion
2018-06-26 13:56:42 +02:00
bors
764232cb2a
Auto merge of #51805 - pietroalbini:rollup, r=pietroalbini
...
Rollup of 11 pull requests
Successful merges:
- #51104 (add `dyn ` to display of dynamic (trait) types)
- #51153 (Link panic and compile_error docs)
- #51642 (Fix unknown windows build)
- #51730 (New safe associated functions for PinMut)
- #51731 (Fix ICEs when using continue as an array length inside closures (inside loop conditions))
- #51747 (Add error for using null characters in #[export_name])
- #51769 (Update broken rustc-guide links)
- #51786 (Remove unnecessary stat64 pointer casts)
- #51788 (Fix typo)
- #51789 (Don't ICE when performing `lower_pattern_unadjusted` on a `TyError`)
- #51791 (Minify css)
Failed merges:
r? @ghost
2018-06-26 11:20:18 +00:00
Fabian Kössel
bd853a6469
Add unit tests for .mod_euc()
and .div_euc()
2018-06-26 13:09:57 +02:00
Fabian Kössel
daeadc6c2e
Clarify rational behind current implementation of .mod_euc()
2018-06-26 13:09:56 +02:00
Fabian Kössel
af6f0f2e10
Document round-off error in .mod_euc()
-method, see issue #50179
2018-06-26 13:09:55 +02:00
Pietro Albini
a539885450
Rollup merge of #51791 - GuillaumeGomez:minify-css, r=estebank
...
Minify css
Sizes changes:
```
dark.css: 8821 => 7804 (~11%)
light.css: 8587 => 7565 (~11%)
rustdoc.css: 22364 => 17818 (~20%)
settings.css: 1384 => 1236 (~10%)
```
So obviously, the bigger the file, the bigger minification.
r? @QuietMisdreavus
2018-06-26 11:35:45 +02:00
Pietro Albini
f2a099b17f
Rollup merge of #51789 - estebank:issue-50577, r=oli-obk
...
Don't ICE when performing `lower_pattern_unadjusted` on a `TyError`
Fix #50577 . CC #51696 .
r? @oli-obk
2018-06-26 11:35:44 +02:00
Pietro Albini
8014713805
Rollup merge of #51788 - berkus:fix-typo, r=varkor
...
Fix typo
2018-06-26 11:35:43 +02:00