summary refs log tree commit diff
path: root/src
AgeCommit message (Collapse)AuthorLines
2016-01-19Add an impl for Box<Error> from &str.Michael Sproul-0/+9
2016-01-19Add an impl for Box<Error> from String.Michael Sproul-0/+27
Closes #30156.
2016-01-16rustc: Fix bugs in renamed and removed lints and re-add raw_pointer_deriveBrian Anderson-38/+269
cc #30346 Conflicts: src/librustc_lint/lib.rs
2016-01-16Move some #[no_std] info to stable book.Steve Klabnik-89/+52
This feature is partially stabilized, so describe each part in the appropriate place. Conflicts: src/doc/book/no-stdlib.md
2016-01-14Fix rustdoc reexports.Lee Jeffery-1/+1
2016-01-12Merge pull request #30854 from brson/beta-next3Alex Crichton-293/+209
More beta ports
2016-01-12Use --cfg when running doctestsSeo Sanghyeon-7/+29
Previously passed --cfg was used only when collecting doctests.
2016-01-12Fix Universal CRT detection on weird setupsPeter Atashian-2/+9
Checks for a `10.` prefix on the subfolder Signed-off-by: Peter Atashian <retep998@gmail.com>
2016-01-12Overhaul MSVC linker and Windows SDK detection codePeter Atashian-286/+173
Fixes https://github.com/rust-lang/rust/issues/30229 Signed-off-by: Peter Atashian <retep998@gmail.com>
2016-01-12Merge pull request #30853 from brson/beta-next2Alex Crichton-2/+19
[beta] Add test for "malformed macro lhs" and change back span_bug to span_f…
2016-01-12Add test for "malformed macro lhs" and change back span_bug to span_fatalGuillaume Gomez-2/+19
2016-01-12Fix link in char docsSteve Klabnik-3/+4
2016-01-12Fix extra space in str docsSteve Klabnik-1/+1
2016-01-12Merge pull request #30847 from nikomatsakis/issue-29857-betaBrian Anderson-40/+115
[beta] Backport fix for issue 29857
2016-01-12The lint warnings are not reported since we report the errors first and then ↵Felix S. Klock II-2/+0
exit. I think that behavior is fine, so I am removing the expected warnings from these tests.
2016-01-12Added proper lint for the unit variant/struct warning.Felix S. Klock II-15/+29
2016-01-12updated test to reflect loosening of check (for issue #30379).Felix S. Klock II-2/+6
2016-01-12extend warning cycle to cover matching unit-structs via `S(..)`Felix S. Klock II-5/+10
(this makes them handled like enum unit-variants.)
2016-01-12improve visibility of future-incompatibilities (mildly, at least)Niko Matsakis-3/+23
2016-01-12Update test -- here we get a RFC 1214 warning (that will eventually beNiko Matsakis-1/+3
an error) but the bugfix causes this warning to propagate and become an unresolved variable instead of a `TyError`, so we wind up seeing an obscure inference error afterwards, which is somewhat unfortunate, and suggests this bugfix can cause RFC 1214 warnings to become errors.
2016-01-11Adjust trait importsNiko Matsakis-2/+1
2016-01-11Minor rebase correctionsNiko Matsakis-1/+2
2016-01-11permit coercions if `[error]` is found in either typeNiko Matsakis-29/+28
Conflicts: src/test/compile-fail/issue-3973.rs
2016-01-11improve cast handling - this fixes test failuresAriel Ben-Yehuda-1/+2
the problem is that now "type_is_known_to_be_sized" now returns false when called on a type with ty_err inside - this prevents spurious errors (we may want to move the check to check::cast anyway - see #12894).
2016-01-11Change error scheme so that if projection fails we generate `A::B` instead ↵Niko Matsakis-10/+83
of `TyError` Conflicts: src/test/compile-fail/issue-29857.rs
2015-12-09Auto merge of #30266 - oli-obk:expr_type_checked, r=luqmanabors-40/+23
r? @eefriedman It was getting out of hand with my additions to the const evaluator
2015-12-09Auto merge of #30278 - steveklabnik:rollup, r=steveklabnikbors-68/+89
- Successful merges: #30201, #30224, #30261, #30273, #30274 - Failed merges:
2015-12-09Rollup merge of #30274 - tshepang:mere-renames, r=steveklabnikSteve Klabnik-52/+5
2015-12-09Rollup merge of #30273 - Xmasreturns:patch-1, r=steveklabnikSteve Klabnik-14/+10
Changes to readability and some clarifications for beginners
2015-12-09Rollup merge of #30261 - oli-obk:add_regression_test, r=pnkfelixSteve Klabnik-0/+37
see https://github.com/rust-lang/rust/pull/30202/files#r46819188 r? @pnkfelix the only difference between the tests is that one has the const_indexing feature enabled.
2015-12-09Rollup merge of #30224 - matklad:super-docs, r=steveklabnikSteve Klabnik-0/+19
Make clear that `super` may be included in the path several times. r? @steveklabnik
2015-12-09Rollup merge of #30201 - GuillaumeGomez:patch-3, r=ManishearthSteve Klabnik-2/+18
r? @Manishearth
2015-12-09Auto merge of #30245 - Aatch:dynamic-align-dst, r=pnkfelixbors-63/+365
Fixes #26403 This adjusts the pointer, if needed, to the correct alignment by using the alignment information in the vtable. Handling zero might not be necessary, as it shouldn't actually occur. I've left it as it's own commit so it can be removed fairly easily if people don't think it's worth doing. The way it's handled though means that there shouldn't be much impact on performance.
2015-12-09Auto merge of #30208 - pnkfelix:fix-issue-30063, r=alexcrichtonbors-1/+92
When given `rustc -C codegen-units=4 --emit=obj`, reset units back to 1. Fix #30063 Note: while this code is careful to handle the case of mutliple emit types (e.g. `--emit=asm,obj`) by reporting all the emit types that conflict with codegen units in its warnings, an invocation with multiple emit types *and* `-o PATH` will continue to ignore the requested target path (with a warning), as it already does today, since the code that checks for that is further downstream. (Multiple emit types without `-o PATH` will "work", though it will downgrade codegen-units to 1 just like all the other cases.) r? @alexcrichton
2015-12-09Auto merge of #30145 - petrochenkov:hyg, r=nrcbors-86/+170
Instead of `ast::Ident`, bindings, paths and labels in HIR now keep a new structure called `hir::Ident` containing mtwt-renamed `name` and the original not-renamed `unhygienic_name`. `name` is supposed to be used by default, `unhygienic_name` is rarely used. This is not ideal, but better than the status quo for two reasons: - MTWT tables can be cleared immediately after lowering to HIR - This is less bug-prone, because it is impossible now to forget applying `mtwt::resolve` to a name. It is still possible to use `name` instead of `unhygienic_name` by mistake, but `unhygienic_name`s are used only in few very special circumstances, so it shouldn't be a problem. Besides name resolution `unhygienic_name` is used in some lints and debuginfo. `unhygienic_name` can be very well approximated by "reverse renaming" `token::intern(name.as_str())` or even plain string `name.as_str()`, except that it would break gensyms like `iter` in desugared `for` loops. This approximation is likely good enough for lints and debuginfo, but not for name resolution, unfortunately (see https://github.com/rust-lang/rust/issues/27639), so `unhygienic_name` has to be kept. cc https://github.com/rust-lang/rust/issues/29782 r? @nrc
2015-12-09doc: these are just renames, so avoid duplicationTshepang Lekhonkhobe-52/+5
2015-12-08Update traits.mdXmasreturns-1/+1
2015-12-08Update traits.mdXmasreturns-14/+10
Changes to readability and some clarifications for beginners
2015-12-08Auto merge of #30271 - steveklabnik:reorder_book, r=aturonbors-12/+12
This ordering was significantly more confusing.
2015-12-08Auto merge of #30036 - mitaa:doc_id, r=alexcrichtonbors-59/+203
This expands the code which generates unique IDs for Markdown headers within a single block to each rendered page. fixes #25001 fixes #29449
2015-12-08Re-order the sections in TRPLSteve Klabnik-12/+12
This ordering was significantly more confusing.
2015-12-08Auto merge of #29995 - DanielJCampbell:Expanded-Span-Printing, r=nrcbors-0/+204
r? @nrc
2015-12-08shorten common if let patterns to function callsOliver Schneider-40/+23
2015-12-08add tests for ensuring const indexing does not cause compile-time errors in ↵Oliver Schneider-0/+37
runtime code
2015-12-08regression test for issue #30063Felix S. Klock II-0/+46
2015-12-08When given `rustc -C codegen-units=4 -o output --emit=obj`, reset units back ↵Felix S. Klock II-1/+46
to 1. Fix #30063 Note: while this code is careful to handle the case of mutliple emit types (e.g. `--emit=asm,obj`) by reporting all the emit types that conflict with codegen units in its warnings, an invocation with multiple emit types *and* `-o PATH` will continue to ignore the requested target path (with a warning), as it already does today, since the code that checks for that is further downstream.
2015-12-08Fix unsized structs with destructorsJames Miller-7/+33
The presence of the drop flag caused the offset calculation to be incorrect, leading to the pointer being incorrect. This has been fixed by calculating the offset based on the field index (and not assuming that the field is always the last one). However, I've also stopped the drop flag from being added to the end of unsized structs to begin with. Since it's not actually accessed for unsized structs, and isn't actually where we would say it is, this made more sense.
2015-12-08Added pretty-printing for span expansion chains through span_to_expanded_string.Daniel Campbell-0/+204
2015-12-07Auto merge of #30087 - petrochenkov:indi, r=nrcbors-193/+176
I've measured the time/memory consumption before and after - the difference is lost in statistical noise, so it's mostly a code simplification. Sizes of `enum`s are not affected. r? @nrc I wonder if AST/HIR visitors could run faster if `P`s are systematically removed (except for cases where they control `enum` sizes). Theoretically they should. Remaining unnecessary `P`s can't be easily removed because many folders accept `P<X>`s as arguments, but these folders can be converted to accept `X`s instead without loss of efficiency. When I have a mood for some mindless refactoring again, I'll probably try to convert the folders, remove remaining `P`s and measure again.
2015-12-07Add comments for Ident::from_name and identifiers in path segmentsVadim Petrochenkov-0/+14