about summary refs log tree commit diff
path: root/src/libsyntax_pos
AgeCommit message (Collapse)AuthorLines
2017-06-19Bump version and stage0 compilerAlex Crichton-6/+2
2017-06-12External spans: address review.Inokentiy Babushkin-15/+20
* The lazy loading mechanism has been moved to a more appropriate place. * Return values from the functions invoked there are properly used. * Documentation has gotten some minor improvements. * Possibly some larger restructuring will need to take place still.
2017-06-11Added hash verification to external source loading.Inokentiy Babushkin-0/+20
2017-06-11Added consumption logic for external sources in FileMapInokentiy Babushkin-18/+28
We now fetch source lines from the `external_src` member as a secondary fallback if no regular source is present, that is, if the file map belongs to an external crate and the source has been fetched from disk.
2017-06-11Improved lazy external source loading and inserted calls.Inokentiy Babushkin-1/+22
2017-06-10Added external crates' sources to FileMap.Inokentiy Babushkin-0/+13
They are now handled in their own member to prevent mutating access to the `src` member. This way, we can safely load external sources, while keeping the mutation of local source strings off-limits.
2017-06-10Moved FileMap construction to it's own constructor.Inokentiy Babushkin-0/+38
The rationale is that BOM stripping is needed for lazy source loading for external crates, and duplication can be avoided by moving the corresponding functionality to libsyntax_pos.
2017-06-10Added source hashes to FileMapInokentiy Babushkin-3/+10
We can use these to perform lazy loading of source files belonging to external crates. That way we will be able to show the source code of external spans that have been translated.
2017-06-05syntax_pos::Symbol should not implement SyncWesley Wiser-0/+1
Fixes #42407
2017-05-25Improve intercrate hygiene.Jeffrey Seyfried-2/+13
2017-05-25Improve efficiency.Jeffrey Seyfried-16/+45
2017-05-25Hygienize `librustc_typeck`.Jeffrey Seyfried-1/+19
2017-05-25Hygienize `librustc_resolve`.Jeffrey Seyfried-24/+172
2017-05-11rustc: Remove #![unstable] annotationAlex Crichton-3/+4
These are now no longer necessary with `-Z force-unstable-if-unmarked`
2017-05-09Add INVALID_CRATE CrateNum constant.Michael Woerister-1/+3
2017-05-08incr.comp.: Hash more pieces of crate metadata to detect changes there.Michael Woerister-0/+4
2017-04-26Implement a file-path remapping feature in support of debuginfo and ↵Michael Woerister-6/+7
reproducible builds.
2017-04-10Point at only one char on `Span::next_point`Esteban Küber-1/+1
Avoid pointing at two chars so the diagnostic output doesn't display a multiline span when starting beyond a line end.
2017-04-05Rollup merge of #40815 - estebank:issue-40006, r=GuillaumeGomezAriel Ben-Yehuda-0/+24
Identify missing item category in `impl`s ```rust struct S; impl S { pub hello_method(&self) { println!("Hello"); } } fn main() { S.hello_method(); } ``` ```rust error: missing `fn` for method declaration --> file.rs:3:4 | 3 | pub hello_method(&self) { | ^ missing `fn` ``` Fix #40006. r? @pnkfelix CC @jonathandturner @GuillaumeGomez
2017-04-04Merge branch 'master' into issue-32540Esteban Küber-37/+678
2017-04-03Merge branch 'master' into issue-40006Esteban Küber-36/+701
2017-03-29Refactor how spans are combined in the parser.Jeffrey Seyfried-6/+10
2017-03-29Merge `ExpnId` and `SyntaxContext`.Jeffrey Seyfried-34/+550
2017-03-29Remove code in `syntax::codemap`.Jeffrey Seyfried-4/+0
2017-03-29Move `syntax::ext::hygiene` to `syntax_pos::hygiene`.Jeffrey Seyfried-0/+125
2017-03-27Fix unittestsEsteban Küber-2/+2
2017-03-25Improve wording and spans for unexpected tokenEsteban Küber-0/+6
* Point at where the token was expected instead of the last token successfuly parsed. * Only show `unexpected token` if the next char and the unexpected token don't have the same span. * Change some cfail and pfail tests to ui test. * Don't show all possible tokens in span label if they are more than 6.
2017-02-02store typeck lints in the `TypeckTables`Niko Matsakis-1/+1
Otherwise they are a "hidden output"
2016-12-29Remove not(stage0) from deny(warnings)Alex Crichton-1/+1
Historically this was done to accommodate bugs in lints, but there hasn't been a bug in a lint since this feature was added which the warnings affected. Let's completely purge warnings from all our stages by denying warnings in all stages. This will also assist in tracking down `stage0` code to be removed whenever we're updating the bootstrap compiler.
2016-11-30Update the bootstrap compilerAlex Crichton-1/+0
Now that we've got a beta build, let's use it!
2016-11-08Group unused import warnings per path listEsteban Küber-3/+3
Given a file ```rust use std::collections::{BinaryHeap, BTreeMap, BTreeSet}; fn main() {} ``` Show a single warning, instead of three for each unused import: ```nocode warning: unused imports, #[warn(unused_imports)] on by default --> foo.rs:1:24 | 1 | use std::collections::{BinaryHeap, BTreeMap, BTreeSet}; | ^^^^^^^^^^ ^^^^^^^^ ^^^^^^^^ ``` Include support for lints pointing at `MultilineSpan`s, instead of just `Span`s.
2016-11-01retool EarlyLint to track a DiagnosticNiko Matsakis-1/+1
2016-10-28Do not intern filemap to entry w/ mismatched length. Fix #37274 (I think).Felix S. Klock II-0/+3
2016-10-12Stabilise `?`Nick Cameron-1/+1
cc [`?` tracking issue](https://github.com/rust-lang/rust/issues/31436)
2016-09-21Auto merge of #36585 - jonathandturner:misc_error_touchups, r=nrcbors-18/+0
Add the ability to merge spans to codemap This PR adds the ability to merge Spans. To do so, it builds on the Codemap's ability to verify the locations of spans, namely that following can be verified: * the expn_id of both spans much match * the lhs span needs to end on the same line the rhs span begins * the lhs span must start at or before the rhs span If all of these are met, a new span is returned that is min(lo), max(hi) of the two spans. This PR also removes an older Span merge, as this new functionality subsumes it. r? @nrc
2016-09-20serialize: allow specifying the default behavior for specializations.Eduard Burtescu-3/+11
2016-09-20rustc_metadata: go only through rustc_serialize in astencode.Eduard Burtescu-15/+2
2016-09-19Add the ability to merge spans to codemapJonathan Turner-18/+0
2016-09-01incr.comp.: Add stable hashing of HIR spans to ICH.Michael Woerister-0/+64
2016-08-17Replace local backtrace with def-use, repair std macro spansJonathan Turner-0/+19
2016-07-30Rollup merge of #35094 - mcarton:multispan, r=jonathandturnerManish Goregaokar-4/+15
Revert "Remove unused methods from MultiSpan" This reverts commit f7019a4e2f80577d38ec35fcebd64d5970b15f78. That commit removed the only way to make a suggestion with more than one substitute. That feature is not used directly by rustc but exists and is used by Clippy. Bring it back until we come up with a better solution (suggestions don't use span labels, so it would make sense for them to use their own type). Rational there: https://github.com/Manishearth/rust-clippy/pull/1119. r? @jonathandturner Cc @Manishearth
2016-07-28Revert "Remove unused methods from MultiSpan"mcarton-4/+15
This reverts commit f7019a4e2f80577d38ec35fcebd64d5970b15f78. This removed the only way to make a suggestion with more than one substitute. Bring it back until we come up with a better solution.
2016-07-25Adressed PR comments.cgswords-0/+4
2016-07-21Remove unused methods from MultiSpanJonathan Turner-15/+4
2016-07-14Implement latest rfc style using simpler renderingJonathan Turner-1/+1
2016-06-23Address comments and fix travis warningJonathan Turner-1/+0
2016-06-23Move errors from libsyntax to its own crateJonathan Turner-0/+680