summary refs log tree commit diff
path: root/src/librustc_const_eval/eval.rs
AgeCommit message (Collapse)AuthorLines
2017-06-13On-demand is_const_fnTaylor Cramer-1/+1
2017-06-10rustc: make the comon case of tcx.infer_ctxt(()) nicer.Eduard-Mihai Burtescu-1/+1
2017-06-01strip param-env from infcxNiko Matsakis-1/+3
2017-06-01move projection mode into parameter environmentNiko Matsakis-1/+1
2017-06-01rustc: remove unnecessary ItemSubsts wrapper.Eduard-Mihai Burtescu-2/+1
2017-05-04trait_of_itemachernyak-1/+1
2017-04-27query for describe_defachernyak-1/+1
2017-04-24rustc: use tcx.at(span) to set the location of a query.Eduard-Mihai Burtescu-1/+1
2017-04-24rustc: expose the common DUMMY_SP query case as tcx methods.Eduard-Mihai Burtescu-2/+2
2017-04-24rustc: rename some of the queries to match tcx methods.Eduard-Mihai Burtescu-3/+3
2017-04-23rustc_const_eval: support all unit enum variants.Eduard-Mihai Burtescu-44/+33
2017-04-23rustc_const_eval: CallOn isn't needed, typeck/const-qualif handle those cases.Eduard-Mihai Burtescu-1/+1
2017-04-23rustc: make the const-eval cache polymorphic.Eduard-Mihai Burtescu-104/+81
2017-04-16rustc: use monomorphic const_eval for cross-crate enum discriminants.Eduard-Mihai Burtescu-4/+7
2017-04-16rustc: expose monomorphic const_eval through on-demand.Eduard-Mihai Burtescu-34/+15
2017-04-16rustc_const_eval: move ConstEvalErr to the rustc crate.Eduard-Mihai Burtescu-170/+6
2017-03-31Don't warn about `char` comparisons in constexprsMatthew Jasper-0/+11
2017-02-25rustc_const_eval: demand that the MIR qualify_consts ran on each evaluated body.Eduard-Mihai Burtescu-1/+2
2017-02-25rustc_const_eval: always demand typeck_tables for evaluating constants.Eduard-Mihai Burtescu-469/+224
2017-02-25rustc_typeck: rework coherence to be almost completely on-demand.Eduard-Mihai Burtescu-1/+1
2017-02-25rustc_typeck: hook up collect and item/body check to on-demand.Eduard-Mihai Burtescu-4/+2
2017-02-25rustc: introduce a query system for type information in ty::maps.Eduard Burtescu-1/+1
2017-02-25rustc: consolidate dep-tracked hashmaps in tcx.maps.Eduard-Mihai Burtescu-5/+5
2017-02-04More snap cleanupSimonas Kazlauskas-6/+3
2017-02-03Bump version, upgrade bootstrapAlex Crichton-2/+0
This commit updates the version number to 1.17.0 as we're not on that version of the nightly compiler, and at the same time this updates src/stage0.txt to bootstrap from freshly minted beta compiler and beta Cargo.
2017-01-31use suggestions instead of helps with code in themOliver Schneider-2/+0
2017-01-26rustc: don't call the HIR AST.Eduard-Mihai Burtescu-5/+5
2017-01-26rustc: rename TyCtxt's `map` field to `hir`.Eduard-Mihai Burtescu-18/+18
2017-01-25rename `Tables` to `TypeckTables`Niko Matsakis-7/+7
2017-01-11Fix two const-eval issues related to i128 negationSimonas Kazlauskas-13/+16
First issue here was the fact that we’d only allow negating integers in i64 range in case the integer was not infered yes. While this is not the direct cause of the issue, its still good to fix it. The real issue here is the code handling specifically the `min_value` literals. While I128_OVERFLOW has the expected value (0x8000_..._0000), match using this value as a pattern is handled incorrectly by the stage1 compiler (it seems to be handled correctly, by the stage2 compiler). So what we do here is extract this pattern into an explicit `==` until the next snapshot. Fixes #38987
2017-01-06rustc: store ty::Tables separately for each body (except closures').Eduard-Mihai Burtescu-29/+43
2017-01-06rustc: keep track of tables everywhere as if they were per-body.Eduard-Mihai Burtescu-181/+179
2017-01-01rustc_const_eval: convert constants to Pattern instead of hir::Pat.Eduard-Mihai Burtescu-127/+3
2016-12-30Such large. Very 128. Much bits.Simonas Kazlauskas-37/+52
This commit introduces 128-bit integers. Stage 2 builds and produces a working compiler which understands and supports 128-bit integers throughout. The general strategy used is to have rustc_i128 module which provides aliases for iu128, equal to iu64 in stage9 and iu128 later. Since nowhere in rustc we rely on large numbers being supported, this strategy is good enough to get past the first bootstrap stages to end up with a fully working 128-bit capable compiler. In order for this strategy to work, number of locations had to be changed to use associated max_value/min_value instead of MAX/MIN constants as well as the min_value (or was it max_value?) had to be changed to use xor instead of shift so both 64-bit and 128-bit based consteval works (former not necessarily producing the right results in stage1). This commit includes manual merge conflict resolution changes from a rebase by @est31.
2016-12-28rustc: always print nested nodes where a HIR map is available.Eduard-Mihai Burtescu-1/+2
2016-12-28rustc: simplify constant cross-crate loading and rustc_passes::consts.Eduard-Mihai Burtescu-75/+17
2016-12-28rustc: move function arguments into hir::Body.Eduard-Mihai Burtescu-11/+9
2016-12-28rustc: separate bodies for static/(associated)const and embedded constants.Eduard-Mihai Burtescu-20/+27
2016-12-28rustc: separate TraitItem from their parent Item, just like ImplItem.Eduard-Mihai Burtescu-1/+1
2016-11-29Fix rebase breakageFlorian Diebold-3/+6
2016-11-29Refactor inlined items some moreFlorian Diebold-19/+28
They don't implement FnLikeNode anymore, instead are handled differently further up in the call tree. Also, keep less information (just def ids for the args).
2016-11-29Add make tidy fixesFlorian Diebold-8/+11
2016-11-29Fix cross-crate associated constant evaluationFlorian Diebold-12/+30
2016-11-29Give function bodies their own dep graph nodeFlorian Diebold-1/+0
2016-11-29Save bodies of functions for inlining into other cratesFlorian Diebold-42/+9
This is quite hacky and I hope to refactor it a bit, but at least it seems to work.
2016-11-29rustc_const_eval: fix compilationFlorian Diebold-1/+2
2016-11-28rustc: embed path resolutions into the HIR instead of keeping DefMap.Eduard-Mihai Burtescu-36/+38
2016-11-28rustc: desugar UFCS as much as possible during HIR lowering.Eduard Burtescu-21/+25
2016-11-22Change HirVec<P<T>> to HirVec<T> in Expr.Nicholas Nethercote-1/+1
This changes structures like this: ``` [ ExprArray | 8 | P ] | v [ P | P | P | P | P | P | P | P ] | v [ ExprTup | 2 | P ] | v [ P | P ] | v [ Expr ] ``` to this: ``` [ ExprArray | 8 | P ] | v [ [ ExprTup | 2 | P ] | ... ] | v [ Expr | Expr ] ```
2016-11-21Use `Symbol` instead of `InternedString` in the AST, HIR, and various other ↵Jeffrey Seyfried-5/+5
places.