Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stabilize suggestion applicability field in json output #50486

Merged
merged 3 commits into from
May 22, 2018

Conversation

Manishearth
Copy link
Member

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label May 6, 2018
@Manishearth Manishearth added I-nominated T-dev-tools Relevant to the dev-tools subteam, which will review and decide on the PR/issue. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels May 6, 2018
@Manishearth
Copy link
Member Author

We should start work on stabilizing the field now so that it's ready for the edition. This also makes it easier for the rustfix preview.

It's an extra field in JSON, I don't think this is something we need to worry much about stabilizing.

@rust-highfive
Copy link
Collaborator

The job x86_64-gnu-llvm-3.9 of your PR failed on Travis (raw log). Through arcane magic we have determined that the following fragments from the build log may contain information about the problem.

Click to expand the log.
[00:06:07]    Compiling rustc_data_structures v0.0.0 (file:///checkout/src/librustc_data_structures)
[00:06:12]    Compiling syntax_pos v0.0.0 (file:///checkout/src/libsyntax_pos)
[00:06:12]    Compiling arena v0.0.0 (file:///checkout/src/libarena)
[00:06:21]    Compiling rustc_errors v0.0.0 (file:///checkout/src/librustc_errors)
[00:06:33] error[E0061]: this function takes 3 parameters but 4 parameters were supplied
[00:06:33]   --> libsyntax/json.rs:59:9
[00:06:33]    |
[00:06:33] 45 | /     pub fn stderr(registry: Option<Registry>,
[00:06:33] 46 | |                   code_map: Lrc<CodeMap>,
[00:06:33] 47 | |                   pretty: bool) -> JsonEmitter {
[00:06:33] 48 | |         JsonEmitter {
[00:06:33] 54 | |         }
[00:06:33] 55 | |     }
[00:06:33]    | |_____- defined here
[00:06:33] ...
[00:06:33] ...
[00:06:33] 59 | /         JsonEmitter::stderr(None, Lrc::new(CodeMap::new(file_path_mapping)),
[00:06:33] 60 | |                             pretty, false)
[00:06:33] 
ff7380f27f57.rlib --extern bitflags=/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps/libbitflags-401bddd0d1809e53.rlib --extern scoped_tls=/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps/libscoped_tls-875ad97a99641bc3.rlib --extern rustc_data_structures=/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_data_structures-f456f53371aa074c.so --extern syntax_pos=/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps/libsyntax_pos-b9901acb1e9e6766.so` (exit code: 101)
ff7380f27f57.rlib --extern bitflags=/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps/libbitflags-401bddd0d1809e53.rlib --extern scoped_tls=/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps/libscoped_tls-875ad97a99641bc3.rlib --extern rustc_data_structures=/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_data_structures-f456f53371aa074c.so --extern syntax_pos=/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps/libsyntax_pos-b9901acb1e9e6766.so` (exit code: 101)
[00:06:38] command did not execute successfully: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0/bin/cargo" "build" "--target" "x86_64-unknown-linux-gnu" "--release" "--locked" "--color" "always" "--features" " jemalloc" "--manifest-path" "/checkout/src/rustc/Cargo.toml" "--message-format" "json"
[00:06:38] expected success, got: exit code: 101
[00:06:38] thread 'main' panicked at 'cargo must succeed', bootstrap/compile.rs:1091:9
[00:06:38] travis_fold:end:stage0-rustc

[00:06:38] travis_time:end:stage0-rustc:start=1525639165693094394,finish=1525639236235535085,duration=70542440691


[00:06:38] failed to run: /checkout/obj/build/bootstrap/debug/bootstrap build
[00:06:38] Build completed unsuccessfully in 0:01:25
[00:06:38] Makefile:28: recipe for target 'all' failed
[00:06:38] make: *** [all] Error 1

The command "stamp sh -x -c "$RUN_SCRIPT"" exited with 2.
travis_time:start:0a3c23f2
$ date && (curl -fs --head https://google.com | grep ^Date: | sed 's/Date: //g' || true)

I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact @TimNN. (Feature Requests)

Copy link
Member

@killercup killercup left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉

@@ -137,7 +131,6 @@ struct DiagnosticSpan {
/// that should be sliced in atop this span.
suggested_replacement: Option<String>,
/// If the suggestion is approximate
#[rustc_serialize_exclude_null]
suggestion_applicability: Option<Applicability>,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Am I reading the code below correctly as: suggestion_applicability is always Some when suggested_replacement is Some? If so, we might want to document this here.

@shepmaster shepmaster added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label May 6, 2018
@pietroalbini pietroalbini added the relnotes Marks issues that should be documented in the release notes of the next release. label May 7, 2018
@nrc
Copy link
Member

nrc commented May 8, 2018

@bors: r+

@bors
Copy link
Contributor

bors commented May 8, 2018

📌 Commit 7e49317 has been approved by nrc

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels May 8, 2018
@kennytm
Copy link
Member

kennytm commented May 9, 2018

@bors r-

The error in #50486 (comment) is still not fixed.

@bors bors added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels May 9, 2018
@Manishearth
Copy link
Member Author

@bors r=nrc

@bors
Copy link
Contributor

bors commented May 9, 2018

📌 Commit bdac0f7 has been approved by nrc

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels May 9, 2018
@rust-highfive

This comment has been minimized.

@Manishearth
Copy link
Member Author

@bors r=nrc

@bors
Copy link
Contributor

bors commented May 9, 2018

📌 Commit 5116598 has been approved by nrc

@rust-highfive
Copy link
Collaborator

The job x86_64-gnu-llvm-3.9 of your PR failed on Travis (raw log). Through arcane magic we have determined that the following fragments from the build log may contain information about the problem.

Click to expand the log.
ruby 2.4.1p111 (2017-03-22 revision 58053) [x86_64-linux]
travis_fold:end:system_info

Network availability confirmed.
Running apt-get update by default has been disabled.
You can opt into running apt-get update by setting this in your .travis.yml file:
  apt:
travis_fold:start:git.checkout
travis_time:start:00375fb5
$ git clone --depth=2 https://github.com/rust-lang/rust.git rust-lang/rust
---
[00:45:25] ....................................................................................................
[00:45:29] ....................................................................................................
[00:45:35] ....................................................................................................
[00:45:40] ....................................................................................................
[00:45:46] ...............................................................................FF...................
[00:45:57] ..................i.................................................................................
[00:46:03] .....................................ii.............................................................
[00:46:10] ....................................................................................................
[00:46:16] .................i....................................................................
[00:46:16] .................i....................................................................
[00:46:16] failures:
[00:46:16] 
[00:46:16] ---- [ui] ui/lint/unused_parens_json_suggestion.rs stdout ----
[00:46:16]  diff of stderr:
[00:46:16] 
[00:46:16] 24       ],
[00:46:16] 25       "label": null,
[00:46:16] 26       "suggested_replacement": null,
[00:46:16] +       "suggestion_applicability": null,
[00:46:16] 27       "expansion": null
[00:46:16] 29   ],
[00:46:16] 
[00:46:16] 51           ],
[00:46:16] 51           ],
[00:46:16] 52           "label": null,
[00:46:16] 53           "suggested_replacement": null,
[00:46:16] +           "suggestion_applicability": null,
[00:46:16] 54           "expansion": null
[00:46:16] 56       ],
[00:46:16] 
[00:46:16] 80           ],
[00:46:16] 80           ],
[00:46:16] 81           "label": null,
[00:46:16] 82           "suggested_replacement": "1 / (2 + 3)",
[00:46:16] +           "suggestion_applicability": "Unspecified",
[00:46:16] 83           "expansion": null
[00:46:16] 85       ],
[00:46:16] 
[00:46:16] 
[00:46:16] The actual stderr differed from the expected stderr.
[00:46:16] The actual stderr differed from the expected stderr.
[00:46:16] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/lint/unused_parens_json_suggestion.stderr
[00:46:16] To update references, run this command from build directory:
[00:46:16] /checkout/src/test/ui/update-references.sh '/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui' 'lint/unused_parens_json_suggestion.rs'
[00:46:16] error: 1 errors occurred comparing output.
[00:46:16] status: exit code: 0
[00:46:16] status: exit code: 0
[00:46:16] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/lint/unused_parens_json_suggestion.rs" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui" "--target=x86_64-unknown-linux-gnu" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/lint/unused_parens_json_suggestion.stage2-x86_64-unknown-linux-gnu" "-Crpath" "-O" "-Zunstable-options" "-Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "--error-format" "pretty-json" "-Zunstable-options" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/lint/unused_parens_json_suggestion.stage2-x86_64-unknown-linux-gnu.aux" "-A" "unused"
[00:46:16] ------------------------------------------
[00:46:16] 
[00:46:16] ------------------------------------------
[00:46:16] stderr:
[00:46:16] stderr:
[00:46:16] ------------------------------------------
[00:46:16] {
[00:46:16]   "message": "unnecessary parentheses around assigned value",
[00:46:16]   "code": {
[00:46:16]     "code": "unused_parens",
[00:46:16]     "explanation": null
[00:46:16]   },
[00:46:16]   "level": "warning",
[00:46:16]   "spans": [
[00:46:16]     {
[00:46:16]       "file_name": "/checkout/src/test/ui/lint/unused_parens_json_suggestion.rs",
[00:46:16]       "byte_start": 1043,
[00:46:16]       "byte_end": 1056,
[00:46:16]       "line_start": 25,
[00:46:16]       "line_end": 25,
[00:46:16]       "column_start": 14,
[00:46:16]       "column_end": 27,
[00:46:16]       "is_primary": true,
[00:46:16]       "text": [
[00:46:16]         {
[00:46:16]           "text": "    let _a = (1 / (2 + 3));",
[00:46:16]           "highlight_start": 14,
[00:46:16]           "highlight_end": 27
[00:46:16]       ],
[00:46:16]       ],
[00:46:16]       "label": null,
[00:46:16]       "suggested_replacement": null,
[00:46:16]       "suggestion_applicability": null,
[00:46:16]       "expansion": null
[00:46:16]   ],
[00:46:16]   ],
[00:46:16]   "children": [
[00:46:16]     {
[00:46:16]       "message": "lint level defined here",
[00:46:16]       "code": null,
[00:46:16]       "level": "note",
[00:46:16]       "spans": [
[00:46:16]         {
[00:46:16]           "file_name": "/checkout/src/test/ui/lint/unused_parens_json_suggestion.rs",
[00:46:16]           "byte_start": 889,
[00:46:16]           "byte_end": 902,
[00:46:16]           "line_start": 20,
[00:46:16]           "line_end": 20,
[00:46:16]           "column_start": 9,
[00:46:16]           "column_end": 22,
[00:46:16]           "is_primary": true,
[00:46:16]           "text": [
[00:46:16]             {
[00:46:16]               "text": "#![warn(unused_parens)]",
[00:46:16]               "highlight_start": 9,
[00:46:16]               "highlight_end": 22
[00:46:16]           ],
[00:46:16]           ],
[00:46:16]           "label": null,
[00:46:16]           "suggested_replacement": null,
[00:46:16]           "suggestion_applicability": null,
[00:46:16]           "expansion": null
[00:46:16]       ],
[00:46:16]       ],
[00:46:16]       "children": [],
[00:46:16]       "rendered": null
[00:46:16]     {
[00:46:16]     {
[00:46:16]       "message": "remove these parentheses",
[00:46:16]       "code": null,
[00:46:16]       "level": "help",
[00:46:16]       "spans": [
[00:46:16]         {
[00:46:16]           "file_name": "/checkout/src/test/ui/lint/unused_parens_json_suggestion.rs",
[00:46:16]           "byte_start": 1043,
[00:46:16]           "byte_end": 1056,
[00:46:16]           "line_start": 25,
[00:46:16]           "line_end": 25,
[00:46:16]           "column_start": 14,
[00:46:16]           "column_end": 27,
[00:46:16]           "is_primary": true,
[00:46:16]           "text": [
[00:46:16]             {
[00:46:16]               "text": "    let _a = (1 / (2 + 3));",
[00:46:16]               "highlight_start": 14,
[00:46:16]               "highlight_end": 27
[00:46:16]           ],
[00:46:16]           ],
[00:46:16]           "label": null,
[00:46:16]           "suggested_replacement": "1 / (2 + 3)",
[00:46:16]           "suggestion_applicability": "Unspecified",
[00:46:16]           "expansion": null
[00:46:16]       ],
[00:46:16]       ],
[00:46:16]       "children": [],
[00:46:16]       "rendered": null
[00:46:16]   ],
[00:46:16]   ],
[00:46:16]   "rendered": "warning: unnecessary parentheses around assigned value\n  --> /checkout/src/test/ui/lint/unused_parens_json_suggestion.rs:25:14\n   |\nLL |     let _a = (1 / (2 + 3));\n   |              ^^^^^^^^^^^^^ help: remove these parentheses\n   |\nnote: lint level defined here\n  --> /checkout/src/test/ui/lint/unused_parens_json_suggestion.rs:20:9\n   |\nLL | #![warn(unused_parens)]\n   |         ^^^^^^^^^^^^^\n\n"
[00:46:16] }
[00:46:16] ------------------------------------------
[00:46:16] 
[00:46:16] thread '[ui] ui/lint/unused_parens_json_suggestion.rs' panicked at 'explicit panic', tools/compiletest/src/runtest.rs:3033:9
[00:46:16] note: Run with `RUST_BACKTRACE=1` for a backtrace.
[00:46:16] note: Run with `RUST_BACKTRACE=1` for a backtrace.
[00:46:16] 
[00:46:16] ---- [ui] ui/lint/use_suggestion_json.rs stdout ----
[00:46:16]  diff of stderr:
[00:46:16] 
[00:46:16] 89       ],
[00:46:16] 90       "label": "not found in this scope",
[00:46:16] 91       "suggested_replacement": null,
[00:46:16] +       "suggestion_applicability": null,
[00:46:16] 92       "expansion": null
[00:46:16] 94   ],
[00:46:16] 
[00:46:16] 
[00:46:16] 118           "suggested_replacement": "use std::collections::binary_heap::Iter;
[00:46:16] thread 'main' panicked at 'Some tests failed', tools/compiletest/src/main.rs:492:22
[00:46:16] 120 ",
[00:46:16] 120 ",
[00:46:16] +           "suggestion_applicability": "Unspecified",
[00:46:16] 121           "expansion": null
[00:46:16] 123         {
[00:46:16] 
[00:46:16] 
[00:46:16] 140           "suggested_replacement": "use std::collections::btree_map::Iter;
[00:46:16] 142 ",
[00:46:16] 142 ",
[00:46:16] +           "suggestion_applicability": "Unspecified",
[00:46:16] 143           "expansion": null
[00:46:16] 145         {
[00:46:16] 
[00:46:16] 
[00:46:16] 162           "suggested_replacement": "use std::collections::btree_set::Iter;
[00:46:16] 164 ",
[00:46:16] 164 ",
[00:46:16] +           "suggestion_applicability": "Unspecified",
[00:46:16] 165           "expansion": null
[00:46:16] 167         {
[00:46:16] 
[00:46:16] 
[00:46:16] 184           "suggested_replacement": "use std::collections::hash_map::Iter;
[00:46:16] 186 ",
[00:46:16] 186 ",
[00:46:16] +           "suggestion_applicability": "Unspecified",
[00:46:16] 187           "expansion": null
[00:46:16] 189         {
[00:46:16] 
[00:46:16] 
[00:46:16] 206           "suggested_replacement": "use std::collections::hash_set::Iter;
[00:46:16] 208 ",
[00:46:16] 208 ",
[00:46:16] +           "suggestion_applicability": "Unspecified",
[00:46:16] 209           "expansion": null
[00:46:16] 211         {
[00:46:16] 
[00:46:16] 
[00:46:16] 228           "suggested_replacement": "use std::collections::linked_list::Iter;
[00:46:16] 230 ",
[00:46:16] 230 ",
[00:46:16] +           "suggestion_applicability": "Unspecified",
[00:46:16] 231           "expansion": null
[00:46:16] 233         {
[00:46:16] 
[00:46:16] 
[00:46:16] 250           "suggested_replacement": "use std::collections::vec_deque::Iter;
[00:46:16] 252 ",
[00:46:16] 252 ",
[00:46:16] +           "suggestion_applicability": "Unspecified",
[00:46:16] 253           "expansion": null
[00:46:16] 255         {
[00:46:16] 
[00:46:16] 
[00:46:16] 272           "suggested_replacement": "use std::option::Iter;
[00:46:16] 274 ",
[00:46:16] 274 ",
[00:46:16] +           "suggestion_applicability": "Unspecified",
[00:46:16] 275           "expansion": null
[00:46:16] 277         {
[00:46:16] 
[00:46:16] 
[00:46:16] 294           "suggested_replacement": "use std::path::Iter;
[00:46:16] 296 ",
[00:46:16] 296 ",
[00:46:16] +           "suggestion_applicability": "Unspecified",
[00:46:16] 297           "expansion": null
[00:46:16] 299         {
[00:46:16] 
[00:46:16] 
[00:46:16] 316           "suggested_replacement": "use std::result::Iter;
[00:46:16] 318 ",
[00:46:16] 318 ",
[00:46:16] +           "suggestion_applicability": "Unspecified",
[00:46:16] 319           "expansion": null
[00:46:16] 321         {
[00:46:16] 
[00:46:16] 
[00:46:16] 338           "suggested_replacement": "use std::slice::Iter;
[00:46:16] 340 ",
[00:46:16] 340 ",
[00:46:16] +           "suggestion_applicability": "Unspecified",
[00:46:16] 341           "expansion": null
[00:46:16] 343         {
[00:46:16] 
[00:46:16] 
[00:46:16] 360           "suggested_replacement": "use std::sync::mpsc::Iter;
[00:46:16] 362 ",
[00:46:16] 362 ",
[00:46:16] +           "suggestion_applicability": "Unspecified",
[00:46:16] 363           "expansion": null
[00:46:16] 365       ],
[00:46:16] 
[00:46:16] 
[00:46:16] The actual stderr differed from the expected stderr.
[00:46:16] The actual stderr differed from the expected stderr.
[00:46:16] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/lint/use_suggestion_json.stderr
[00:46:16] To update references, run this command from build directory:
[00:46:16] /checkout/src/test/ui/update-references.sh '/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui' 'lint/use_suggestion_json.rs'
[00:46:16] error: 1 errors occurred comparing output.
[00:46:16] status: exit code: 101
[00:46:16] status: exit code: 101
[00:46:16] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/lint/use_suggestion_json.rs" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui" "--target=x86_64-unknown-linux-gnu" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/lint/use_suggestion_json.stage2-x86_64-unknown-linux-gnu" "-Crpath" "-O" "-Zunstable-options" "-Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "--error-format" "pretty-json" "-Zunstable-options" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/lint/use_suggestion_json.stage2-x86_64-unknown-linux-gnu.aux" "-A" "unused"
[00:46:16] ------------------------------------------
[00:46:16] 
[00:46:16] ------------------------------------------
[00:46:16] stderr:
[00:46:16] stderr:
[00:46:16] ------------------------------------------
[00:46:16] {
[00:46:16]   "message": "cannot find type `Iter` in this scope",
[00:46:16]   "code": {
[00:46:16]     "code": "E0412",
[00:46:16]     "explanation": "\nThe type name used is not in scope.\n\nErroneous code examples:\n\n```compile_fail,E0412\nimpl Something {} // error: type name `Something` is not in scope\n\n// or:\n\ntrait Foo {\n    fn bar(N); // error: type name `N` is not in scope\n}\n\n// or:\n\nfn foo(x: T) {} // type name `T` is not in scope\n```\n\nTo fix this error, please verify you didn't misspell the type name, you did\ndeclare it or imported it into the scope. Examples:\n\n```\nstruct Something;\n\nimpl Something {} // ok!\n\n// or:\n\ntrait Foo {\n    type N;\n\n    fn bar(_: Self::N); // ok!\n}\n\n// or:\n\nfn foo<T>(x: T) {} // ok!\n```\n\nAnother case that causes this error is when a type is imported into a parent\nmodule. To fix this, you can follow the suggestion and use File directly or\n`use super::File;` which will import the types from the parent namespace. An\nexample that causes this error is below:\n\n```compile_fail,E0412\nuse std::fs::File;\n\nmod foo {\n    fn some_function(f: File) {}\n}\n```\n\n```\nuse std::fs::File;\n\nmod foo {\n    // either\n    use super::File;\n    // or\n    // use std::fs::File;\n    fn foo(f: File) {}\n}\n# fn main() {} // don't insert it for us; that'll break imports\n```\n"
[00:46:16]   },
[00:46:16]   "level": "error",
[00:46:16]   "spans": [
[00:46:16]     {
[00:46:16]       "file_name": "/checkout/src/test/ui/lint/use_suggestion_json.rs",
[00:46:16]       "byte_start": 907,
[00:46:16]       "byte_end": 911,
[00:46:16]       "line_start": 21,
[00:46:16]       "line_end": 21,
[00:46:16]       "column_start": 12,
[00:46:16]       "column_end": 16,
[00:46:16]       "is_primary": true,
[00:46:16]       "text": [
[00:46:16]         {
[00:46:16]           "text": "    let x: Iter;",
[00:46:16]           "highlight_start": 12,
[00:46:16]           "highlight_end": 16
[00:46:16]       ],
[00:46:16]       ],
[00:46:16]       "label": "not found in this scope",
[00:46:16]       "suggested_replacement": null,
[00:46:16]       "suggestion_applicability": null,
[00:46:16]       "expansion": null
[00:46:16]   ],
[00:46:16]   ],
[00:46:16]   "children": [
[00:46:16]     {
[00:46:16]       "message": "possible candidates are found in other modules, you can import them into scope",
[00:46:16]       "code": null,
[00:46:16]       "level": "help",
[00:46:16]       "spans": [
[00:46:16]         {
[00:46:16]           "file_name": "/checkout/src/test/ui/lint/use_suggestion_json.rs",
[00:46:16]           "byte_start": 884,
[00:46:16]           "byte_end": 884,
[00:46:16]           "line_start": 20,
[00:46:16]           "line_end": 20,
[00:46:16]           "column_start": 1,
[00:46:16]           "column_end": 1,
[00:46:16]           "is_primary": true,
[00:46:16]           "text": [
[00:46:16]             {
[00:46:16]               "text": "fn main() {",
[00:46:16]               "highlight_start": 1,
[00:46:16]               "highlight_end": 1
[00:46:16]           ],
[00:46:16]           ],
[00:46:16]           "label": null,
[00:46:16]           "suggested_replacement": "use std::collections::binary_heap::Iter;\n\n",
[00:46:16]           "suggestion_applicability": "Unspecified",
[00:46:16]           "expansion": null
[00:46:16]         {
[00:46:16]         {
[00:46:16]           "file_name": "/checkout/src/test/ui/lint/use_suggestion_json.rs",
[00:46:16]           "byte_start": 884,
[00:46:16]           "byte_end": 884,
[00:46:16]           "line_start": 20,
[00:46:16]           "line_end": 20,
[00:46:16]           "column_start": 1,
[00:46:16]           "column_end": 1,
[00:46:16]           "is_primary": true,
[00:46:16]           "text": [
[00:46:16]             {
[00:46:16]               "text": "fn main() {",
[00:46:16]               "highlight_start": 1,
[00:46:16]               "highlight_end": 1
[00:46:16]           ],
[00:46:16]           ],
[00:46:16]           "label": null,
[00:46:16]           "suggested_replacement": "use std::collections::btree_map::Iter;\n\n",
[00:46:16]           "suggestion_applicability": "Unspecified",
[00:46:16]           "expansion": null
[00:46:16]         {
[00:46:16]         {
[00:46:16]           "file_name": "/checkout/src/test/ui/lint/use_suggestion_json.rs",
[00:46:16]           "byte_start": 884,
[00:46:16]           "byte_end": 884,
[00:46:16]           "line_start": 20,
[00:46:16]           "line_end": 20,
[00:46:16]           "column_start": 1,
[00:46:16]           "column_end": 1,
[00:46:16]           "is_primary": true,
[00:46:16]           "text": [
[00:46:16]             {
[00:46:16]               "text": "fn main() {",
[00:46:16]               "highlight_start": 1,
[00:46:16]               "highlight_end": 1
[00:46:16]           ],
[00:46:16]           ],
[00:46:16]           "label": null,
[00:46:16]           "suggested_replacement": "use std::collections::btree_set::Iter;\n\n",
[00:46:16]           "suggestion_applicability": "Unspecified",
[00:46:16]           "expansion": null
[00:46:16]         {
[00:46:16]         {
[00:46:16]           "file_name": "/checkout/src/test/ui/lint/use_suggestion_json.rs",
[00:46:16]           "byte_start": 884,
[00:46:16]           "byte_end": 884,
[00:46:16]           "line_start": 20,
[00:46:16]           "line_end": 20,
[00:46:16]           "column_start": 1,
[00:46:16]           "column_end": 1,
[00:46:16]           "is_primary": true,
[00:46:16]           "text": [
[00:46:16]             {
[00:46:16]               "text": "fn main() {",
[00:46:16]               "highlight_start": 1,
[00:46:16]               "highlight_end": 1
[00:46:16]           ],
[00:46:16]           ],
[00:46:16]           "label": null,
[00:46:16]           "suggested_replacement": "use std::collections::hash_map::Iter;\n\n",
[00:46:16]           "suggestion_applicability": "Unspecified",
[00:46:16]           "expansion": null
[00:46:16]         {
[00:46:16]         {
[00:46:16]           "file_name": "/checkout/src/test/ui/lint/use_suggestion_json.rs",
[00:46:16]           "byte_start": 884,
[00:46:16]           "byte_end": 884,
[00:46:16]           "line_start": 20,
[00:46:16]           "line_end": 20,
[00:46:16]           "column_start": 1,
[00:46:16]           "column_end": 1,
[00:46:16]           "is_primary": true,
[00:46:16]           "text": [
[00:46:16]             {
[00:46:16]               "text": "fn main() {",
[00:46:16]               "highlight_start": 1,
[00:46:16]               "highlight_end": 1
[00:46:16]           ],
[00:46:16]           ],
[00:46:16]           "label": null,
[00:46:16]           "suggested_replacement": "use std::collections::hash_set::Iter;\n\n",
[00:46:16]           "suggestion_applicability": "Unspecified",
[00:46:16]           "expansion": null
[00:46:16]         {
[00:46:16]         {
[00:46:16]           "file_name": "/checkout/src/test/ui/lint/use_suggestion_json.rs",
[00:46:16]           "byte_start": 884,
[00:46:16]           "byte_end": 884,
[00:46:16]           "line_start": 20,
[00:46:16]           "line_end": 20,
[00:46:16]           "column_start": 1,
[00:46:16]           "column_end": 1,
[00:46:16]           "is_primary": true,
[00:46:16]           "text": [
[00:46:16]             {
[00:46:16]               "text": "fn main() {",
[00:46:16]               "highlight_start": 1,
[00:46:16]               "highlight_end": 1
[00:46:16]           ],
[00:46:16]           ],
[00:46:16]           "label": null,
[00:46:16]           "suggested_replacement": "use std::collections::linked_list::Iter;\n\n",
[00:46:16]           "suggestion_applicability": "Unspecified",
[00:46:16]           "expansion": null
[00:46:16]         {
[00:46:16]         {
[00:46:16]           "file_name": "/checkout/src/test/ui/lint/use_suggestion_json.rs",
[00:46:16]           "byte_start": 884,
[00:46:16]           "byte_end": 884,
[00:46:16]           "line_start": 20,
[00:46:16]           "line_end": 20,
[00:46:16]           "column_start": 1,
[00:46:16]           "column_end": 1,
[00:46:16]           "is_primary": true,
[00:46:16]           "text": [
[00:46:16]             {
[00:46:16]               "text": "fn main() {",
[00:46:16]               "highlight_start": 1,
[00:46:16]               "highlight_end": 1
[00:46:16]           ],
[00:46:16]           ],
[00:46:16]           "label": null,
[00:46:16]           "suggested_replacement": "use std::collections::vec_deque::Iter;\n\n",
[00:46:16]           "suggestion_applicability": "Unspecified",
[00:46:16]           "expansion": null
[00:46:16]         {
[00:46:16]         {
[00:46:16]           "file_name": "/checkout/src/test/ui/lint/use_suggestion_json.rs",
[00:46:16]           "byte_start": 884,
[00:46:16]           "byte_end": 884,
[00:46:16]           "line_start": 20,
[00:46:16]           "line_end": 20,
[00:46:16]           "column_start": 1,
[00:46:16]           "column_end": 1,
[00:46:16]           "is_primary": true,
[00:46:16]           "text": [
[00:46:16]             {
[00:46:16]               "text": "fn main() {",
[00:46:16]               "highlight_start": 1,
[00:46:16]               "highlight_end": 1
[00:46:16]           ],
[00:46:16]           ],
[00:46:16]           "label": null,
[00:46:16]           "suggested_replacement": "use std::option::Iter;\n\n",
[00:46:16]           "suggestion_applicability": "Unspecified",
[00:46:16]           "expansion": null
[00:46:16]         {
[00:46:16]         {
[00:46:16]           "file_name": "/checkout/src/test/ui/lint/use_suggestion_json.rs",
[00:46:16]           "byte_start": 884,
[00:46:16]           "byte_end": 884,
[00:46:16]           "line_start": 20,
[00:46:16]           "line_end": 20,
[00:46:16]           "column_start": 1,
[00:46:16]           "column_end": 1,
[00:46:16]           "is_primary": true,
[00:46:16]           "text": [
[00:46:16]             {
[00:46:16]               "text": "fn main() {",
[00:46:16]               "highlight_start": 1,
[00:46:16]               "highlight_end": 1
[00:46:16]           ],
[00:46:16]           ],
[00:46:16]           "label": null,
[00:46:16]           "suggested_replacement": "use std::path::Iter;\n\n",
[00:46:16]           "suggestion_applicability": "Unspecified",
---
[00:46:16] test result: FAILED. 1377 passed; 2 failed; 7 ignored; 0 measured; 0 filtered out
[00:46:16] 
[00:46:16] 
[00:46:16] 
[00:46:16] command did not execute successfully: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-tools-bin/compiletest" "--compile-lib-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib" "--run-lib-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/x86_64-unknown-linux-gnu/lib" "--rustc-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "--src-base" "/checkout/src/test/ui" "--build-base" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui" "--stage-id" "stage2-x86_64-unknown-linux-gnu" "--mode" "ui" "--target" "x86_64-unknown-linux-gnu" "--host" "x86_64-unknown-linux-gnu" "--llvm-filecheck" "/usr/lib/llvm-3.9/bin/FileCheck" "--host-rustcflags" "-Crpath -O -Zunstable-options " "--target-rustcflags" "-Crpath -O -Zunstable-options  -Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "--docck-python" "/usr/bin/python2.7" "--lldb-python" "/usr/bin/python2.7" "--gdb" "/usr/bin/gdb" "--quiet" "--llvm-version" "3.9.1\n" "--system-llvm" "--cc" "" "--cxx" "" "--cflags" "" "--llvm-components" "" "--llvm-cxxflags" "" "--adb-path" "adb" "--adb-test-dir" "/data/tmp/work" "--android-cross-path" "" "--color" "always"
[00:46:16] 
[00:46:16] 
[00:46:16] failed to run: /checkout/obj/build/bootstrap/debug/bootstrap test
[00:46:16] Build completed unsuccessfully in 0:02:28
[00:46:16] Build completed unsuccessfully in 0:02:28
[00:46:16] Makefile:58: recipe for target 'check' failed
[00:46:16] make: *** [check] Error 1

The command "stamp sh -x -c "$RUN_SCRIPT"" exited with 2.
travis_time:start:2777df90
$ date && (curl -fs --head https://google.com | grep ^Date: | sed 's/Date: //g' || true)

I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact @TimNN. (Feature Requests)

@Manishearth
Copy link
Member Author

@bors r-

I'll need to update the ui tests

@bors bors added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels May 9, 2018
@bors
Copy link
Contributor

bors commented May 13, 2018

☔ The latest upstream changes (presumably #50235) made this pull request unmergeable. Please resolve the merge conflicts.

@pietroalbini
Copy link
Member

Ping from triage @Manishearth! It's been a while since we heard from you, will you have time to work on this again soon?

@Manishearth
Copy link
Member Author

@bors r=nrc

@bors
Copy link
Contributor

bors commented May 21, 2018

📌 Commit b0e6638 has been approved by nrc

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels May 21, 2018
@bors
Copy link
Contributor

bors commented May 22, 2018

⌛ Testing commit b0e6638 with merge 38fd7ea...

bors added a commit that referenced this pull request May 22, 2018
Stabilize suggestion applicability field in json output

cc @killercup

r? @nrc
@bors
Copy link
Contributor

bors commented May 22, 2018

☀️ Test successful - status-appveyor, status-travis
Approved by: nrc
Pushing 38fd7ea to master...

@bors bors merged commit b0e6638 into rust-lang:master May 22, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
relnotes Marks issues that should be documented in the release notes of the next release. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-dev-tools Relevant to the dev-tools subteam, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants