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

Define queries using a proc macro #56462

Open
wants to merge 5 commits into
base: master
from

Conversation

Projects
None yet
10 participants
@Zoxc
Contributor

Zoxc commented Dec 3, 2018

cc @rust-lang/compiler

@rust-highfive

This comment has been minimized.

Collaborator

rust-highfive commented Dec 3, 2018

r? @zackmdavis

(rust_highfive has picked a reviewer for you, use r? to override)

@rust-highfive

This comment was marked as outdated.

Collaborator

rust-highfive commented Dec 3, 2018

The job x86_64-gnu-llvm-5.0 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.
travis_time:end:1733260b:start=1543850730845872634,finish=1543850788076333896,duration=57230461262
$ git checkout -qf FETCH_HEAD
travis_fold:end:git.checkout

Encrypted environment variables have been removed for security reasons.
See https://docs.travis-ci.com/user/pull-requests/#Pull-Requests-and-Security-Restrictions
$ export SCCACHE_BUCKET=rust-lang-ci-sccache2
$ export SCCACHE_REGION=us-west-1
Setting environment variables from .travis.yml
$ export IMAGE=x86_64-gnu-llvm-5.0
---
[00:05:31]    Compiling rustc_data_structures v0.0.0 (/checkout/src/librustc_data_structures)
[00:05:38]    Compiling arena v0.0.0 (/checkout/src/libarena)
[00:05:38]    Compiling syntax_pos v0.0.0 (/checkout/src/libsyntax_pos)
[00:05:52]    Compiling rustc_errors v0.0.0 (/checkout/src/librustc_errors)
[00:06:06]    Compiling rustc_query_macro v0.1.0 (/checkout/src/librustc_query_macro)
[00:07:18]    Compiling syntax_ext v0.0.0 (/checkout/src/libsyntax_ext)
[00:07:19] group [Other] type_of
[00:07:19] QUERY Other { [  ] fn type_of : TypeOf ( DefId ) -> Ty < 'tcx > , } ,
[00:07:19] DEP NODE [  ] TypeOf ( DefId ) ,
[00:07:19] DEP NODE FORCE DepKind :: TypeOf => {
[00:07:19] force_ex ! ( $ tcx , type_of , def_id_ex ! ( $ dep_node ) ) ; }
[00:07:19] RETURNING macro_rules ! rustc_query_append {
[00:07:19] ( [ $ ( $ macro : tt ) * ] [ $ ( $ other : tt ) * ] ) => {
[00:07:19] $ ( $ macro ) * {
[00:07:19] $ ( $ other ) * Other { [  ] fn type_of : TypeOf ( DefId ) -> Ty < 'tcx > , }
[00:07:19] , } } } macro_rules ! rustc_dep_node_append {
[00:07:19] ( [ $ ( $ macro : tt ) * ] [ $ ( $ other : tt ) * ] ) => {
[00:07:19] $ ( $ macro ) * ( $ ( $ other ) * [  ] TypeOf ( DefId ) , ) ; } } macro_rules
[00:07:19] ! rustc_dep_node_force {
[00:07:19] ( [ $ dep_node : expr , $ tcx : expr ] $ ( $ other : tt ) * ) => {
[00:07:19] match $ dep_node . kind {
[00:07:19] $ ( $ other ) * DepKind :: TypeOf => {
[00:07:19] force_ex ! ( $ tcx , type_of , def_id_ex ! ( $ dep_node ) ) ; } } } }
[00:13:10]    Compiling rustc_typeck v0.0.0 (/checkout/src/librustc_typeck)
[00:13:10]    Compiling rustc_typeck v0.0.0 (/checkout/src/librustc_typeck)
[00:13:10] error[E0425]: cannot find value `TypeOfItem` in module `label_strs`
[00:13:10]   --> src/librustc_incremental/persist/dirty_clean.rs:50:17
[00:13:10]    |
[00:13:10] 50 |     label_strs::TypeOfItem,
[00:13:10]    |                 ^^^^^^^^^^ not found in `label_strs`
[00:13:10] 
[00:13:10] error[E0425]: cannot find value `TypeOfItem` in module `label_strs`
[00:13:10]   --> src/librustc_incremental/persist/dirty_clean.rs:59:17
[00:13:10]    |
[00:13:10] 59 |     label_strs::TypeOfItem,
[00:13:10]    |                 ^^^^^^^^^^ not found in `label_strs`
[00:13:10] 
[00:13:10] error[E0425]: cannot find value `TypeOfItem` in module `label_strs`
[00:13:10]   --> src/librustc_incremental/persist/dirty_clean.rs:94:17
[00:13:10]    |
[00:13:10] 94 |     label_strs::TypeOfItem,
[00:13:10]    |                 ^^^^^^^^^^ not found in `label_strs`
[00:13:11] error: aborting due to 3 previous errors
[00:13:11] 
[00:13:11] For more information about this error, try `rustc --explain E0425`.
[00:13:11] error: Could not compile `rustc_incremental`.
---
184272 ./obj/build/cache/2018-10-30
159708 ./obj/build/x86_64-unknown-linux-gnu/stage0-rustc
153284 ./src/tools/clang
150356 ./obj/build/bootstrap/debug/incremental
134764 ./obj/build/bootstrap/debug/incremental/bootstrap-2oigu19tl6bg6
134760 ./obj/build/bootstrap/debug/incremental/bootstrap-2oigu19tl6bg6/s-f78zbczu1w-1iibz2p-35hdvoweuro4i
134004 ./.git/modules/src
115352 ./src/llvm/test/CodeGen
107892 ./obj/build/x86_64-unknown-linux-gnu/stage0/lib/rustlib/x86_64-unknown-linux-gnu/codegen-backends
107416 ./src/tools/lldb
---
travis_time:end:17a9aa98:start=1543851809405176344,finish=1543851809411059496,duration=5883152
travis_fold:end:after_failure.3
travis_fold:start:after_failure.4
travis_time:start:2680d436
$ ln -s . checkout && for CORE in obj/cores/core.*; do EXE=$(echo $CORE | sed 's|obj/cores/core\.[0-9]*\.!checkout!\(.*\)|\1|;y|!|/|'); if [ -f "$EXE" ]; then printf travis_fold":start:crashlog\n\033[31;1m%s\033[0m\n" "$CORE"; gdb --batch -q -c "$CORE" "$EXE" -iex 'set auto-load off' -iex 'dir src/' -iex 'set sysroot .' -ex bt -ex q; echo travis_fold":"end:crashlog; fi; done || true
travis_fold:end:after_failure.4
travis_fold:start:after_failure.5
travis_time:start:0048ec20
travis_time:start:0048ec20
$ cat ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers || true
cat: ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers: No such file or direc

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)


rustc_query_append! { [define_queries!][ <'tcx>

This comment has been minimized.

@eddyb

eddyb Dec 3, 2018

Member

This is mind-bending, but cool!

@Zoxc Zoxc force-pushed the Zoxc:query-macro branch from f648f18 to f17866d Dec 3, 2018

@rust-highfive

This comment was marked as outdated.

Collaborator

rust-highfive commented Dec 3, 2018

The job x86_64-gnu-llvm-5.0 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.
travis_time:end:0df5dd84:start=1543853811483088899,finish=1543853883734079907,duration=72250991008
$ git checkout -qf FETCH_HEAD
travis_fold:end:git.checkout

Encrypted environment variables have been removed for security reasons.
See https://docs.travis-ci.com/user/pull-requests/#Pull-Requests-and-Security-Restrictions
$ export SCCACHE_BUCKET=rust-lang-ci-sccache2
$ export SCCACHE_REGION=us-west-1
Setting environment variables from .travis.yml
$ export IMAGE=x86_64-gnu-llvm-5.0
---
[00:04:58]    Compiling rustc-rayon v0.1.1
[00:05:06]    Compiling rustc_data_structures v0.0.0 (/checkout/src/librustc_data_structures)
[00:05:18]    Compiling arena v0.0.0 (/checkout/src/libarena)
[00:05:19]    Compiling syntax_pos v0.0.0 (/checkout/src/libsyntax_pos)
[00:05:19]    Compiling rustc_query_macro v0.1.0 (/checkout/src/librustc_query_macro)
[00:06:40]    Compiling syntax_ext v0.0.0 (/checkout/src/libsyntax_ext)
[00:06:40]    Compiling syntax_ext v0.0.0 (/checkout/src/libsyntax_ext)
[00:06:41] group [Other] type_of
[00:06:41] QUERY Other { [  ] fn type_of : TypeOf ( DefId ) -> Ty < 'tcx > , } ,
[00:06:41] DEP NODE [  ] TypeOf ( DefId ) ,
[00:06:41] DEP NODE FORCE DepKind :: TypeOf => {
[00:06:41] force_ex ! ( $ tcx , type_of , def_id_ex ! ( $ dep_node ) ) ; }
[00:06:41] RETURNING macro_rules ! rustc_query_append {
[00:06:41] ( [ $ ( $ macro : tt ) * ] [ $ ( $ other : tt ) * ] ) => {
[00:06:41] $ ( $ macro ) * {
[00:06:41] $ ( $ other ) * Other { [  ] fn type_of : TypeOf ( DefId ) -> Ty < 'tcx > , }
[00:06:41] , } } } macro_rules ! rustc_dep_node_append {
[00:06:41] ( [ $ ( $ macro : tt ) * ] [ $ ( $ other : tt ) * ] ) => {
[00:06:41] $ ( $ macro ) * ( $ ( $ other ) * [  ] TypeOf ( DefId ) , ) ; } } macro_rules
[00:06:41] ! rustc_dep_node_force {
[00:06:41] ( [ $ dep_node : expr , $ tcx : expr ] $ ( $ other : tt ) * ) => {
[00:06:41] match $ dep_node . kind {
[00:06:41] $ ( $ other ) * DepKind :: TypeOf => {
[00:06:41] force_ex ! ( $ tcx , type_of , def_id_ex ! ( $ dep_node ) ) ; } } } }
[00:12:02]    Compiling rustc_typeck v0.0.0 (/checkout/src/librustc_typeck)
[00:13:25]    Compiling rustc_traits v0.0.0 (/checkout/src/librustc_traits)
[00:14:55]    Compiling rustc_allocator v0.0.0 (/checkout/src/librustc_allocator)
[00:14:56]    Compiling rustc_resolve v0.0.0 (/checkout/src/librustc_resolve)
---
[00:20:57]    Compiling rustc-rayon v0.1.1
[00:21:05]    Compiling rustc_data_structures v0.0.0 (/checkout/src/librustc_data_structures)
[00:21:17]    Compiling arena v0.0.0 (/checkout/src/libarena)
[00:21:18]    Compiling syntax_pos v0.0.0 (/checkout/src/libsyntax_pos)
[00:21:18]    Compiling rustc_query_macro v0.1.0 (/checkout/src/librustc_query_macro)
[00:22:49]    Compiling syntax_ext v0.0.0 (/checkout/src/libsyntax_ext)
[00:22:49]    Compiling syntax_ext v0.0.0 (/checkout/src/libsyntax_ext)
[00:22:50] group [Other] type_of
[00:22:50] QUERY Other { [  ] fn type_of : TypeOf ( DefId ) -> Ty < 'tcx > , } ,
[00:22:50] DEP NODE [  ] TypeOf ( DefId ) ,
[00:22:50] DEP NODE FORCE DepKind :: TypeOf => {
[00:22:50] force_ex ! ( $ tcx , type_of , def_id_ex ! ( $ dep_node ) ) ; }
[00:22:50] RETURNING macro_rules ! rustc_query_append {
[00:22:50] ( [ $ ( $ macro : tt ) * ] [ $ ( $ other : tt ) * ] ) => {
[00:22:50] $ ( $ macro ) * {
[00:22:50] $ ( $ other ) * Other { [  ] fn type_of : TypeOf ( DefId ) -> Ty < 'tcx > , }
[00:22:50] , } } } macro_rules ! rustc_dep_node_append {
[00:22:50] ( [ $ ( $ macro : tt ) * ] [ $ ( $ other : tt ) * ] ) => {
[00:22:50] $ ( $ macro ) * ( $ ( $ other ) * [  ] TypeOf ( DefId ) , ) ; } } macro_rules
[00:22:50] ! rustc_dep_node_force {
[00:22:50] ( [ $ dep_node : expr , $ tcx : expr ] $ ( $ other : tt ) * ) => {
[00:22:50] match $ dep_node . kind {
[00:22:50] $ ( $ other ) * DepKind :: TypeOf => {
[00:22:50] force_ex ! ( $ tcx , type_of , def_id_ex ! ( $ dep_node ) ) ; } } } }
[00:28:22]    Compiling rustc_typeck v0.0.0 (/checkout/src/librustc_typeck)
[00:31:14]    Compiling rustc_traits v0.0.0 (/checkout/src/librustc_traits)
[00:31:14]    Compiling rustc_allocator v0.0.0 (/checkout/src/librustc_allocator)
[00:32:31]    Compiling rustc_plugin v0.0.0 (/checkout/src/librustc_plugin)
---
[00:43:47] .................................................................................................... 400/5107
[00:43:50] .................................................................................................... 500/5107
[00:43:53] ..............................i..................................................................... 600/5107
[00:43:56] .................................................................................................... 700/5107
[00:44:02] ..................................................................................................i. 800/5107
[00:44:06] ..............i......F...F.......................................................................... 900/5107
[00:44:09] .....................i.iiii......................................................................... 1000/5107
[00:44:13] .................................................................................................... 1200/5107
[00:44:15] .................................................................................................... 1300/5107
[00:44:18] .................................................................................................... 1400/5107
[00:44:20] .................................................................................................... 1500/5107
---
[00:46:12] 55 error: OK
[00:46:12] 56   --> $DIR/dep-graph-struct-signature.rs:70:9
[00:46:12] 
[00:46:12] 57    |
[00:46:12] - LL |         #[rustc_then_this_would_need(TypeOfItem)] //~ ERROR OK
[00:46:12] -    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[00:46:12] + LL |         #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK
[00:46:12] 60 
[00:46:12] 61 error: OK
[00:46:12] 62   --> $DIR/dep-graph-struct-signature.rs:72:9
[00:46:12] 
[00:46:12] 
[00:46:12] 63    |
[00:46:12] - LL |         #[rustc_then_this_would_need(TypeOfItem)] //~ ERROR OK
[00:46:12] -    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[00:46:12] + LL |         #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK
[00:46:12] 66 
[00:46:12] 66 
[00:46:12] - error: no path from `WillChange` to `TypeOfItem`
[00:46:12] + error: no path from `WillChange` to `TypeOf`
[00:46:12] 69    |
[00:46:12] 69    |
[00:46:12] - LL |     #[rustc_then_this_would_need(TypeOfItem)] //~ ERROR no path
[00:46:12] -    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[00:46:12] + LL |     #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path
[00:46:12] 72 
[00:46:12] 72 
[00:46:12] - error: no path from `WillChange` to `TypeOfItem`
[00:46:12] + error: no path from `WillChange` to `TypeOf`
[00:46:12] 75    |
[00:46:12] 75    |
[00:46:12] - LL |     #[rustc_----------------------------------
[00:46:12] ------------------------------------------
[00:46:12] ------------------------------------------
[00:46:12] {"message":"no path from `WillChange` to `TypeOf`","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":878,"byte_end":915,"line_start":37,"line_end":37,"column_start":5,"column_end":42,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path","highlight_start":5,"highlight_end":42}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: no path from `WillChange` to `TypeOf`\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:37:5\n   |\nLL |     #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"no path from `WillChange` to `AssociatedItems`","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":938,"byte_end":984,"line_start":38,"line_end":38,"column_start":5,"column_end":51,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(AssociatedItems)] //~ ERROR no path","highlight_start":5,"highlight_end":51}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: no path from `WillChange` to `AssociatedItems`\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:38:5\n   |\nLL |     #[rustc_then_this_would_need(AssociatedItems)] //~ ERROR no path\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"no path from `WillChange` to `TraitDefOfItem`","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":1007,"byte_end":1052,"line_start":39,"line_end":39,"column_start":5,"column_end":50,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(TraitDefOfItem)] //~ ERROR no path","highlight_start":5,"highlight_end":50}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: no path from `WillChange` to `TraitDefOfItem`\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:39:5\n   |\nLL |     #[rustc_then_this_would_need(TraitDefOfItem)] //~ ERROR no path\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":1202,"byte_end":1244,"line_start":45,"line_end":45,"column_start":5,"column_end":47,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(FnSignature)] //~ ERROR OK","highlight_start":5,"highlight_end":47}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:45:5\n   |\nLL |     #[rustc_then_this_would_need(FnSignature)] //~ ERROR OK\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/eckTables)] //~ ERROR OK","highlight_start":5,"highlight_end":48}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:50:5\n   |\nLL |     #[rustc_then_this_would_need(TypeckTables)] //~ ERROR OK\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":1567,"byte_end":1604,"line_start":55,"line_end":55,"column_start":5,"column_end":42,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK","highlight_start":5,"highlight_end":42}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:55:5\n   |\nLL |     #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":1838,"byte_end":1875,"line_start":62,"line_end":62,"column_start":5,"column_end":42,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK","highlight_start":5,"highlight_end":42}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":2330,"byte_end":2367,"line_start":77,"line_end":77,"column_start":5,"column_end":42,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path","highlight_start":5,"highlight_end":42}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: no path from `WillChange` to `TypeOf`\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:77:5\n   |\nLL |     #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"no path from `WillChange` to `TypeOf`","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":2475,"byte_end":2512,"line_start":84,"line_end":84,"column_start":5,"column_end":42,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path","highlight_start":5,"highlight_end":42}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: no path from `WillChange` to `TypeOf`\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:84:5\n   |\nLL |     #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"no path from `WillChange` to `FnSignature`","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":2676,"byte_end":2718,"line_start":90,"line_end":90,"column_start":5,"column_end":47,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(FnSignature)] //~ ERROR no path","highlight_start":5,"highlight_end":47}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: no path from `WillChange` to `FnSignature`\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:90:5\n   |\nLL |     #[rustc_then_this_would_need(FnSignature)] //~ ERROR no path\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"no path from `WillChange` to `FnSignature`","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":2770,"byte_end":2812,"line_start":93,"line_end":93,"column_start":5,"column_end":47,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(FnSignature)] //~ ERROR no path from `WillChange`","highlight_start":5,"highlight_end":47}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: no path from `WillChange` to `FnSignature`\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:93:5\n   |\nLL |     #[rustc_then_this_would_need(FnSignature)] //~ ERROR no path from `WillChange`\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"no path from `WillChange` to `TypeckTables`","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":2853,"byte_end":2896,"line_start":94,"line_end":94,"column_start":5,"column_end":48,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(TypeckTables)] //~ ERROR no path from `WillChange`","highlight_start":5,"highlight_end":48}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: no path from `WillChange` to `TypeckTables`\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:94:5\n   |\nLL |     #[rustc_then_this_would_need(TypeckTables)] //~ ERROR no path from `WillChange`\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":1095,"byte_end":1137,"line_start":41,"line_end":41,"column_start":9,"column_end":51,"is_primary":true,"text":[{"text":"        #[rustc_then_this_would_need(FnSignature)] //~ ERROR OK","highlight_start":9,"highlight_end":51}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:41:9\n   |\nLL |         #[rustc_then_this_would_need(FnSignature)] //~ ERROR OK\n   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"no path from `WillChange` to `FnSignature`","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":2553,"byte_end":2595,"line_start":86,"line_end":86,"column_start":9,"column_end":51,"is_primary":true,"text":[{"text":"        #[rustc_then_this_would_need(FnSignature)] //~ ERROR no path","highlight_start":9,"highlight_end":51}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: no path from `WillChange` to `FnSignature`\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:86:9\n   |\nLL |         #[rustc_then_this_would_need(FnSignature)] //~ ERROR no path\n   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":1648,"byte_end":1690,"line_start":57,"line_end":57,"column_start":9,"column_end":51,"is_primary":true,"text":[{"text":"        #[rustc_then_this_would_need(FnSignature)] //~ ERROR OK","highlight_start":9,"highlight_end":51}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:57:9\n   |\nLL |         #[rustc_then_this_would_need(FnSignature)] //~ ERROR OK\n   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":1712,"byte_end":1755,"line_start":58,"line_end":58,"column_start":9,"column_end":52,"is_primary":true,"text":[{"text":"        #[rustc_then_this_would_need(TypeckTables)] //~ ERROR OK","highlight_start":9,"highlight_end":52}],"label":null,"suggested_replacement":null,"suggustc_then_this_would_need(TypeOf)] //~ ERROR no path
[00:46:12] 36 
[00:46:12] 37 error: OK
[00:46:12] 38   --> $DIR/dep-graph-type-alias.rs:59:1
[00:46:12] 
[00:46:12] 
[00:46:12] 39    |
[00:46:12] - LL | #[rustc_then_this_would_need(TypeOfItem)] //~ ERROR OK
[00:46:12] -    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[00:46:12] + LL | #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK
[00:46:12] 42 
[00:46:12] 43 error: OK
[00:46:12] 44   --> $DIR/dep-graph-type-alias.rs:62:1
[00:46:12] 
[00:46:12] 
[00:46:12] 
[00:46:12] The actual stderr differed from the expected stderr.
[00:46:12] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/dep-graph/dep-graph-type-alias/dep-graph-type-alias.stderr
[00:46:12] To update references, rerun the tests and pass the `--bless` flag
[00:46:12] To only update this specific test, also pass `--test-args dep-graph/dep-graph-type-alias.rs`
[00:46:12] error: 1 errors occurred comparing output.
[00:46:12] status: exit code: 1
[00:46:12] status: exit code: 1
[00:46:12] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/dep-graph/dep-graph-type-alias/a" "-Crpath" "-O" "-Zunstable-options" "-Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "-Z" "query-dep-graph" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/dep-graph/dep-graph-type-alias/auxiliary" "-A" "unused"
[00:46:12] ------------------------------------------
[00:46:12] 
[00:46:12] ------------------------------------------
[00:46:12] stderr:
[00:46:12] stderr:
[00:46:12] ------------------------------------------
[00:46:12] {"message":"no path from `TypeAlias` to `TypeOf`","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs","byte_start":802,"byte_end":839,"line_start":28,"line_end":28,"column_start":1,"column_end":38,"is_primary":true,"text":[{"text":"#[rustc_then_this_would_need(TypeOf)] //~ ERROR no path","highlight_start":1,"highlight_end":38}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: no path from `TypeAlias` to `TypeOf`\n  --> /checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs:28:1\n   |\nLL | #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path\n   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs","byte_start":878,"byte_end":915,"line_start":30,"line_end":30,"column_start":5,"column_end":42,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK","highlight_start":5,"highlight_end":42}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs:30:5\n   |\nLL |     #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK\n   |  s.rs","byte_start":1152,"byte_end":1189,"line_start":44,"line_end":44,"column_start":1,"column_end":38,"is_primary":true,"text":[{"text":"#[rustc_then_this_would_need(TypeOf)] //~ ERROR no path","highlight_start":1,"highlight_end":38}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: no path from `TypeAlias` to `TypeOf`\n  --> /checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs:44:1\n   |\nLL | #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path\n   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"no path from `TypeAlias` to `TypeOf`","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs","byte_start":1339,"byte_end":1376,"line_start":52,"line_end":52,"column_start":1,"column_end":38,"is_primary":true,"text":[{"text":"#[rustc_then_this_would_need(TypeOf)] //~ ERROR no path","highlight_start":1,"highlight_end":38}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: no path from `TypeAlias` to `TypeOf`\n  --> /checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs:52:1\n   |\nLL | #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path\n   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs","byte_start":1573,"byte_end":1610,"line_start":59,"line_end":59,"column_start":1,"column_end":38,"is_primary":true,"text":[{"text":"#[rustc_then_this_would_need(TypeOf)] //~ ERROR OK"es)] //~ ERROR OK\n   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs","byte_start":1226,"byte_end":1268,"line_start":46,"line_end":46,"column_start":5,"column_end":47,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(FnSignature)] //~ ERROR OK","highlight_start":5,"highlight_end":47}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs:46:5\n   |\nLL |     #[rustc_then_this_would_need(FnSignature)] //~ ERROR OK\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs","byte_start":1415,"byte_end":1457,"line_start":54,"line_end":54,"column_start":5,"column_end":47,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(FnSignature)] //~ ERROR OK","highlight_start":5,"highlight_end":47}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs:54:5\n   |\nLL |     #[rustc_then_this_would_need(FnSignature)] //~ ERROR OK\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:46:12] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs","byte_start":1475,"byte_end":1518,"line_start": "--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-5.0/bin/FileCheck" "--host-rustcflags" "-Crpath -O -Zunstable-options  -Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "--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" "5.0.0\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:12] 
[00:46:12] 
[00:46:12] failed to run: /checkout/obj/build/bootstrap/debug/bootstrap test
[00:46:12] Build completed unsuccessfully in 0:03:39
[00:46:12] Build completed unsuccessfully in 0:03:39
[00:46:12] make: *** [check] Error 1
[00:46:12] Makefile:58: recipe for target 'check' failed
The command "stamp sh -x -c "$RUN_SCRIPT"" exited with 2.
travis_time:start:27002e77
$ date && (curl -fs --head https://google.com | grep ^Date: | sed 's/Date: //g' || true)
Mon Dec  3 17:04:24 UTC 2018
---
travis_time:end:0ba09a09:start=1543856665929268237,finish=1543856665933144290,duration=3876053
travis_fold:end:after_failure.3
travis_fold:start:after_failure.4
travis_time:start:226aeccb
$ ln -s . checkout && for CORE in obj/cores/core.*; do EXE=$(echo $CORE | sed 's|obj/cores/core\.[0-9]*\.!checkout!\(.*\)|\1|;y|

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)

@Zoxc Zoxc force-pushed the Zoxc:query-macro branch 2 times, most recently from 92fcbc5 to 20b9c1b Dec 3, 2018

Show resolved Hide resolved src/librustc/query/mod.rs Outdated
@rust-highfive

This comment was marked as outdated.

Collaborator

rust-highfive commented Dec 3, 2018

The job x86_64-gnu-llvm-5.0 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.
travis_time:end:1efe4e1c:start=1543857523969641245,finish=1543857587712825312,duration=63743184067
$ git checkout -qf FETCH_HEAD
travis_fold:end:git.checkout

Encrypted environment variables have been removed for security reasons.
See https://docs.travis-ci.com/user/pull-requests/#Pull-Requests-and-Security-Restrictions
$ export SCCACHE_BUCKET=rust-lang-ci-sccache2
$ export SCCACHE_REGION=us-west-1
Setting environment variables from .travis.yml
$ export IMAGE=x86_64-gnu-llvm-5.0
---
[00:41:24] .................................................................................................... 400/5107
[00:41:27] .................................................................................................... 500/5107
[00:41:30] ..............................i..................................................................... 600/5107
[00:41:33] .................................................................................................... 700/5107
[00:41:38] ..................................................................................................i. 800/5107
[00:41:41] ..............i......F...F.......................................................................... 900/5107
[00:41:44] .....................iiiii.......................................................................... 1000/5107
[00:41:48] .................................................................................................... 1200/5107
[00:41:50] .................................................................................................... 1300/5107
[00:41:52] .................................................................................................... 1400/5107
[00:41:54] .................................................................................................... 1500/5107
---
[00:43:34] diff of stderr:
[00:43:34] 
[00:43:34] 2   --> $DIR/dep-graph-struct-signature.rs:37:5
[00:43:34] 3    |
[00:43:34] 4 LL |     #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path
[00:43:34] +    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[00:43:34] 6 
[00:43:34] 6 
[00:43:34] 7 error: no path from `WillChange` to `AssociatedItems`
[00:43:34] 
[00:43:34] 44   --> $DIR/dep-graph-struct-signature.rs:55:5
[00:43:34] 45    |
[00:43:34] 45    |
[00:43:34] 46 LL |     #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK
[00:43:34] +    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[00:43:34] 48 
[00:43:34] 49 error: OK
[00:43:34] 50   --> $DIR/dep-graph-struct-signature.rs:62:5
[00:43:34] 50   --> $DIR/dep-graph-struct-signature.rs:62:5
[00:43:34] 
[00:43:34] 51    |
[00:43:34] 52 LL |     #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK
[00:43:34] +    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[00:43:34] 54 
[00:43:34] 55 error: OK
[00:43:34] 56   --> $DIR/dep-graph-struct-signature.rs:70:9
[00:43:34] 56   --> $DIR/dep-graph-struct-signature.rs:70:9
[00:43:34] 
[00:43:34] 57    |
[00:43:34] 58 LL |         #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK
[00:43:34] +    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[00:43:34] 60 
[00:43:34] 61 error: OK
[00:43:34] 62   --> $DIR/dep-graph-struct-signature.rs:72:9
[00:43:34] 62   --> $DIR/dep-graph-struct-signature.rs:72:9
[00:43:34] 
[00:43:34] 63    |
[00:43:34] 64 LL |         #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK
[00:43:34] +    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[00:43:34] 66 
[00:43:34] 66 
[00:43:34] 67 error: no path from `WillChange` to `TypeOf`
[00:43:34] 
[00:43:34] 69    |
[00:43:34] 69    |
[00:43:34] 70 LL |     #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path
[00:43:34] +    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[00:43:34] 72 
[00:43:34] 72 
[00:43:34] 73 error: no path from `WillChange` to `TypeOf`
[00:43:34] 
[00:43:34] 75    |
[00:43:34] 75    |
[00:43:34] 76 LL |     #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path
[00:43:34] +    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[00:43:34] 78 
[00:43:34] 78 
[00:43:34] 79 error: no path from `WillChange` to `FnSignature`
[00:43:34] 
[00:43:34] 
[00:43:34] The actual stderr differed from the expected stderr.
[00:43:34] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/dep-graph/dep-graph-struct-signature/dep-graph-struct-signature.stderr
[00:43:34] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/dep-graph/dep-graph-struct-signature/dep-graph-struct-signature.stderr
[00:43:34] To update references, rerun the tests and pass the `--bless` flag
[00:43:34] To only update this specific test, also pass `--test-args dep-graph/dep-graph-struct-signature.rs`
[00:43:34] error: 1 errors occurred comparing output.
[00:43:34] status: exit code: 1
[00:43:34] status: exit code: 1
[00:43:34] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/teatedItems)] //~ ERROR no path","highlight_start":5,"highlight_end":51}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: no path from `WillChange` to `AssociatedItems`\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:38:5\n   |\nLL |     #[rustc_then_this_would_need(AssociatedItems)] //~ ERROR no path\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:43:34] {"message":"no path from `WillChange` to `TraitDefOfItem`","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":1007,"byte_end":1052,"line_start":39,"line_end":39,"column_start":5,"column_end":50,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(TraitDefOfItem)] //~ ERROR no path","highlight_start":5,"highlight_end":50}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: no path from `WillChange` to `TraitDefOfItem`\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:39:5\n   |\nLL |     #[rustc_then_this_would_need(TraitDefOfItem)] //~ ERROR no path\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:43:34] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":1202,"byte_end":1244,"line_start":45,"line_end":45,"column_start":5,"column_end":47,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(FnSignature)] //~ ERROR OK","highlight_start":5,"highlight_end":47}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:45:5\n   |\nLL |     #[rustc_then_this_would_need(FnSignature)] //~ ERROR OK\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:43:34] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":1262,"byte_end":1305,"line_start":46,"line_end":46,"column_start":5,"column_end":48,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(TypeckTables)] //~ ERROR OK","highlight_start":5,"highlight_end":48}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:46:5\n   |\nLL |     #[rustc_then_this_would_need(TypeckTables)] //~ ERROR OK\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:43:34] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":1358,"byte_end":1400,"line_start":49,"line_end":49,"column_start":5,"column_end":47,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(FnSignature)] //~ ERROR OK","highlight_start":5,"highlight_end":47}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:49:5\n   |\nLL |     #[rustc_then_this_would_need(FnSignature)] //~ ERROR OK\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:43:34] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":1418,"byte_end":1461,"line_start":50,"line_end":50,"column_start":5,"column_end":48,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(TypeckTables)] //~ ERROR OK","highlight_start":5,"highlight_end":48}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:50:5\n   |\nLL |     #[rustc_then_this_would_need(TypeckTables)] //~ ERROR OK\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:43:34] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":1567,"byte_end":1604,"line_start":55,"line_end":55,"column_start":5,"column_end":42,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK","highlight_start":5,"highlight_end":42}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:55:5\n   |\nLL |     #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:43:34] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":1838,"byte_end":1875,"line_start":62,"line_end":62,"column_start":5,"column_end":42,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK","highlight_start":5,"highlight_end":42}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:62:5\n   |\nLL |     #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:43:34] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":2117,"byte_end":2154,"line_start":70,"line_end":70,"column_start":9,"column_end":46,"is_primary":true,"text":[{"text":"        #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK","highlight_start":9,"highlight_end":46}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:70:9\n   |\nLL |         #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK\n   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:43:34] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":2199,"byte_end":2236,"line_start":72,"line_end":72,"column_start":9,"column_end":46,"is_primary":true,"text":[{"text":"        #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK","highlight_start":9,"highlight_end":46}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:72:9\n   |\nLL |         #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK\n   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:43:34] {"message":"no path from `WillChange` to `TypeOf`","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":2330,"byte_end":2367,"line_start":77,"line_end":77,"column_start":5,"column_end":42,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path","highlight_start":5,"highlight_end":42}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: no path from `WillChange` to `TypeOf`\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:77:5\n   |\nLL |     #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:43:34] thread 'main' panicked at 'Some tests failed', src/tools/compiletest/src/main.rs:503:22
[00:43:34] {"message":"no path from `WillChange` to `TypeOf`","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":2475,"byte_end":2512,"line_start":84,"line_end":84,"column_start":5,"column_end":42,"is_primary":true,"text":[{"text":"    #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path","highlight_start":5,"highlight_end":42}],"label":null,"suggested_replacement":null,"suggesti/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:41:9\n   |\nLL |         #[rustc_then_this_would_need(FnSignature)] //~ ERROR OK\n   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:43:34] {"message":"no path from `WillChange` to `FnSignature`","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":2553,"byte_end":2595,"line_start":86,"line_end":86,"column_start":9,"column_end":51,"is_primary":true,"text":[{"text":"        #[rustc_then_this_would_need(FnSignature)] //~ ERROR no path","highlight_start":9,"highlight_end":51}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: no path from `WillChange` to `FnSignature`\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:86:9\n   |\nLL |         #[rustc_then_this_would_need(FnSignature)] //~ ERROR no path\n   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:43:34] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs","byte_start":1648,"byte_end":1690,"line_start":57,"line_end":57,"column_start":9,"column_end":51,"is_primary":true,"text":[{"text":"        #[rustc_then_this_would_need(FnSignature)] //~ ERROR OK","highlight_start":9,"highlight_end":51}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:57:9\n   |\nLL |         #[rustc_then_this_would_need(FnSh-struct-signature.rs","byte_start":1983,"byte_end":2026,"line_start":65,"line_end":65,"column_start":9,"column_end":52,"is_primary":true,"text":[{"text":"        #[rustc_then_this_would_need(TypeckTables)] //~ ERROR OK","highlight_start":9,"highlight_end":52}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-struct-signature.rs:65:9\n   |\nLL |         #[rustc_then_this_would_need(TypeckTables)] //~ ERROR OK\n   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:43:34] {"message":"aborting due to 22 previous errors","code":null,"level":"error","spans":[],"children":[],"rendered":"error: aborting due to 22 previous errors\n\n"}
[00:43:34] ------------------------------------------
[00:43:34] 
[00:43:34] thread '[ui] ui/dep-graph/dep-graph-struct-signature.rs' panicked at 'explicit panic', src/tools/compiletest/src/runtest.rs:3282:9
[00:43:34] note: Run with `RUST_BACKTRACE=1` for a backtrace.
[00:43:34] note: Run with `RUST_BACKTRACE=1` for a backtrace.
[00:43:34] 
[00:43:34] ---- [ui] ui/dep-graph/dep-graph-type-alias.rs stdout ----
[00:43:34] diff of stderr:
[00:43:34] 
[00:43:34] 2   --> $DIR/dep-graph-type-alias.rs:28:1
[00:43:34] 3    |
[00:43:34] 4 LL | #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path
[00:43:34] +    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[00:43:34] 6 
[00:43:34] 7 error: OK
[00:43:34] 8   --> $DIR/dep-graph-type-alias.rs:30:5
[00:43:34] 8   --> $DIR/dep-graph-type-alias.rs:30:5
[00:43:34] 
[00:43:34] 9    |
[00:43:34] 10 LL |     #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK
[00:43:34] +    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[00:43:34] 12 
[00:43:34] 12 
[00:43:34] 13 error: no path from `TypeAlias` to `TypeOf`
[00:43:34] 
[00:43:34] 15    |
[00:43:34] 15    |
[00:43:34] 16 LL | #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path
[00:43:34] +    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[00:43:34] 18 
[00:43:34] 19 error: OK
[00:43:34] 20   --> $DIR/dep-graph-type-alias.rs:38:9
[00:43:34] 20   --> $DIR/dep-graph-type-alias.rs:38:9
[00:43:34] 
[00:43:34] 21    |
[00:43:34] 22 LL |         #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK
[00:43:34] +    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[00:43:34] 24 
[00:43:34] 24 
[00:43:34] 25 error: no path from `TypeAlias` to `TypeOf`
[00:43:34] 
[00:43:34] 27    |
[00:43:34] 27    |
[00:43:34] 28 LL | #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path
[00:43:34] +    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[00:43:34] 30 
[00:43:34] 30 
[00:43:34] 31 error: no path from `TypeAlias` to `TypeOf`
[00:43:34] 
[00:43:34] 33    |
[00:43:34] 33    |
[00:43:34] 34 LL | #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path
[00:43:34] +    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[00:43:34] 36 
[00:43:34] 37 error: OK
[00:43:34] 38   --> $DIR/dep-graph-type-alias.rs:59:1
[00:43:34] 38   --> $DIR/dep-graph-type-alias.rs:59:1
[00:43:34] 
[00:43:34] 39    |
[00:43:34] 40 LL | #[rustc_then_this_would_need(TypeOf)] //~ ERROR OK
[00:43:34] +    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[00:43:34] 42 
[00:43:34] 43 error: OK
[00:43:34] 44   --> $DIR/dep-graph-type-alias.rs:62:1
[00:43:34] 44   --> $DIR/dep-graph-type-alias.rs:62:1
[00:43:34] 
[00:43:34] 
[00:43:34] The actual stderr differed from the expected stderr.
[00:43:34] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/dep-graph/dep-graph-type-alias/dep-graph-type-alias.stderr
[00:43:34] To update references, rerun the tests and pass the `--bless` flag
[00:43:34] To only update this specific test, also pass `--test-args dep-graph/dep-graph-type-alias.rs`
[00:43:34] error: 1 errors occurred comparing output.
[00:43:34] status: exit code: 1
[00:43:34] status: exit code: 1
[00:43:34] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/dep-graph/dep-graph-type-alias/a" "-Crpath" "-O" "-Zunstable-options" "-Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "-Z" "query-dep-graph" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/dep-graph/dep-graph-type-alias/auxiliary" "-A" "unused"
[00:43:34] ------------------------------------------
[00:43:34] 
[00:43:34] ------------------------------------------
[00:43:34] stderr:
[00:43:34] stderr:
[00:43:34] ------------------------------------------
[00:43:34] {"messagelicability":null,"expansion":null}],"children":[],"rendered":"error: no path from `TypeAlias` to `TypeOf`\n  --> /checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs:44:1\n   |\nLL | #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path\n   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:43:34] {"message":"no path from `TypeAlias` to `TypeOf`","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs","byte_start":1339,"byte_end":1376,"line_start":52,"line_end":52,"column_start":1,"column_end":38,"is_primary":true,"text":[{"text":"#[rustc_then_this_would_need(TypeOf)] //~ ERROR no path","highlight_start":1,"highlight_end":38}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: no path from `TypeAlias` to `TypeOf`\n  --> /checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs:52:1\n   |\nLL | #[rustc_then_this_would_need(TypeOf)] //~ ERROR no path\n   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:43:34] {"message":"OK","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs","byte_start":1573,"byte_end":1610,"line_start":59,"line_end":59,"column_start":1,"column_end":38,"is_primary":true,"text":[{"text":"#[rustc_then_this_would_need(TypeOf)] //~ ERROR OK","highlight_start":1,"highlight_end":38}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs:59:1\n   |\nLL | #[rustc_then_this_would_need(TypeOf)] //~ ],"rendered":"error: OK\n  --> /checkout/src/test/ui/dep-graph/dep-graph-type-alias.rs:55:5\n   |\nLL |     #[rustc_then_this_would_need(TypeckTables)] //~ ERROR OK\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[00:43:34] {"message":"aborting due to 12 previous errors","code":null,"level":"error","spans":[],"children":[],"rendered":"error: aborting due to 12 previous errors\n\n"}
[00:43:34] ------------------------------------------
[00:43:34] 
[00:43:34] thread '[ui] ui/dep-graph/dep-graph-type-alias.rs' panicked at 'explicit panic', src/tools/compiletest/src/runtest.rs:3282:9
[00:43:34] 
---
[00:43:34] test result: FAILED. 5081 passed; 2 failed; 24 ignored; 0 measured; 0 filtered out
[00:43:34] 
[00:43:34] 
[00:43:34] 
[00:43:34] 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-5.0/bin/FileCheck" "--host-rustcflags" "-Crpath -O -Zunstable-options  -Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "--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" "5.0.0\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:43:34] 
[00:43:34] 
[00:43:34] failed to run: /checkout/obj/build/bootstrap/debug/bootstrap test
[00:43:34] Build completed unsuccessfully in 0:03:19
[00:43:34] Build completed unsuccessfully in 0:03:19
[00:43:34] Makefile:58: recipe for target 'check' failed
[00:43:34] make: *** [check] Error 1
32512 ./obj/build/x86_64-unknown-linux-gnu/stage1-std/release
32256 ./obj/build/x86_64-unknown-linux-gnu/doc/src
32036 ./src/llvm/test/Transforms
31568 ./obj/build/x86_64-unknown-linux-gnu/stage0-std/release
---
travis_time:end:2cda1eee:start=1543860213579973975,finish=1543860213583236907,duration=3262932
travis_fold:end:after_failure.3
travis_fold:start:after_failure.4
travis_time:start:17552628
$ ln -s . checkout && for CORE in obj/cores/core.*; do EXE=$(echo $CORE | sed 's|obj/cores/core\.[0-9]*\.!checkout!\(.*\)|\1|;y|

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)

@Zoxc Zoxc force-pushed the Zoxc:query-macro branch from 20b9c1b to 76c53a7 Dec 3, 2018

@mark-i-m

This comment has been minimized.

Contributor

mark-i-m commented Dec 3, 2018

@Zoxc This is cool :)

When it merges, could you please update https://rust-lang.github.io/rustc-guide/query.html ? That would be much appreciated!

@rust-highfive

This comment has been minimized.

Collaborator

rust-highfive commented Dec 3, 2018

The job x86_64-gnu-llvm-5.0 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.
travis_time:end:0255f9b0:start=1543863384381938093,finish=1543863472704537416,duration=88322599323
$ git checkout -qf FETCH_HEAD
travis_fold:end:git.checkout

Encrypted environment variables have been removed for security reasons.
See https://docs.travis-ci.com/user/pull-requests/#Pull-Requests-and-Security-Restrictions
$ export SCCACHE_BUCKET=rust-lang-ci-sccache2
$ export SCCACHE_REGION=us-west-1
Setting environment variables from .travis.yml
$ export IMAGE=x86_64-gnu-llvm-5.0
---
travis_time:start:test_codegen
Check compiletest suite=codegen mode=codegen (x86_64-unknown-linux-gnu -> x86_64-unknown-linux-gnu)
[00:55:53] 
[00:55:53] running 120 tests
[00:55:56] i..ii...iii..iiii.....i...i..........i..iii.............i.....i.....ii...i..i.ii...............i..ii 100/120
[00:55:56] ..ii.i.....iiii.....
[00:55:56] 
[00:55:56]  finished in 3.326
[00:55:56] travis_fold:end:test_codegen

---
travis_time:start:test_debuginfo
Check compiletest suite=debuginfo mode=debuginfo-both (x86_64-unknown-linux-gnu -> x86_64-unknown-linux-gnu)
[00:56:10] 
[00:56:10] running 118 tests
[00:56:33] .iiiii...i.....i..i...i..i.i..i.i..i.....i..i....i..........iiii.........i.i....i...i.......ii.i.i.i 100/118
[00:56:37] ......iii.i.....ii
[00:56:37] 
[00:56:37]  finished in 26.939
[00:56:37] travis_fold:end:test_debuginfo

---
[01:24:24] verifying if humantime is an unstable crate
[01:24:24] verifying if test is an unstable crate
[01:24:24] verifying if termcolor is an unstable crate
[01:24:24] verifying if parking_lot_core is an unstable crate
[01:24:24] verifying if rustc_hash is an unstable crate
[01:24:24] verifying if backtrace_sys is an unstable crate
[01:24:24] verifying if compiler_builtins is an unstable crate
[01:24:24] verifying if cc is an unstable crate
[01:24:24] verifying if quote is an unstable crate
[01:24:24] verifying if rand_core is an unstable crate
[01:24:24] verifying if memoffset is an unstable crate
[01:24:24] verifying if ena is an unstable crate
[01:24:24] verifying if proc_macro2 is an unstable crate
[01:24:24] verifying if num_cpus is an unstable crate
[01:24:24] verifying if crossbeam_utils is an unstable crate
[01:24:24] verifying if rustc_demangle is an unstable crate
[01:24:24] verifying if scoped_tls is an unstable crate
[01:24:24] verifying if crossbeam_deque is an unstable crate
[01:24:24] verifying if datafrog is an unstable crate
[01:24:24] verifying if rustc_serialize is an unstable crate
[01:24:24] verifying if rustc_msan is an unstable crate
[01:24:24] verifying if libc is an unstable crate
[01:24:24] verifying if panic_abort is an unstable crate
[01:24:24] verifying if log_settings is an unstable crate
[01:24:24] verifying if rls_data is an unstable crate
[01:24:24] verifying if memmap is an unstable crate
[01:24:24] verifying if build_helper is an unstable crate
[01:24:24] verifying if build_helper is an unstable crate
[01:24:24] crate build_helper "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/x86_64-unknown-linux-gnu/lib/libbuild_helper-fc70adc6582f8056.rlib" is not unstable
[01:24:24] error[E0514]: found crate `build_helper` compiled by an incompatible version of rustc
[01:24:24]  --> <anon>:1:1
[01:24:24] 1 | extern crate build_helper;
[01:24:24]   | ^^^^^^^^^^^^^^^^^^^^^^^^^^
[01:24:24]   |
[01:24:24]   |
[01:24:24]   = help: please recompile that crate using this compiler (rustc 1.32.0-dev)
[01:24:24]   = note: the following crate versions were found:
[01:24:24]      g if panic_unwind is an unstable crate
[01:24:24] verifying if jobserver is an unstable crate
[01:24:24] verifying if atty is an unstable crate
[01:24:24] verifying if atty is an unstable crate
[01:24:24] verifying if lock_api is an unstable crate
[01:24:24] verifying if cmake is an unstable crate
[01:24:24] crate cmake "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcmake-afb19a8695d09bc4.rlib" is not unstable
[01:24:24] error[E0514]: found crate `cmake` compiled by an incompatible version of rustc
[01:24:24]  --> <anon>:1:1
[01:24:24] 1 | extern crate cmake;
[01:24:24]   | ^^^^^^^^^^^^^^^^^^^
[01:24:24]   |
[01:24:24]   |
[01:24:24]   = help: please recompile that crate using this compiler (rustc 1.32.0-dev)
[01:24:24]   = note: the following crate versions were found:
[01:24:24]           crate `cmake` compiled by rustc 1.31.0-beta.1 (2824a67b0 2018-10-29): /checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcmake-afb19a8695d09bc4.rlib
[01:24:24] error: aborting due to previous error
[01:24:24] 
[01:24:24] For more information about this error, try `rustc --explain E0514`.
[01:24:24] 
---
[01:24:24] 
[01:24:24] ------------------------------------------
[01:24:24] stderr:
[01:24:24] ------------------------------------------
[01:24:24] make[1]: *** [all] Error 1
[01:24:24] ------------------------------------------
[01:24:24] 
[01:24:24] thread '[run-make] run-make-fulldeps/sysroot-crates-are-unstable' panicked at 'explicit panic', src/tools/compiletest/src/runtest.rs:3282:9
[01:24:24] note: Run with `RUST_BACKTRACE=1` for a backtrace.
---
[01:24:24] test result: FAILED. 191 passed; 1 failed; 0 ignored; 0 measured; 0 filtered out
[01:24:24] 
[01:24:24] 
[01:24:24] 
[01:24:24] 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" "--rustdoc-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustdoc" "--src-base" "/checkout/src/test/run-make-fulldeps" "--build-base" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/run-make-fulldeps" "--stage-id" "stage2-x86_64-unknown-linux-gnu" "--mode" "run-make" "--target" "x86_64-unknown-linux-gnu" "--host" "x86_64-unknown-linux-gnu" "--llvm-filecheck" "/usr/lib/llvm-5.0/bin/FileCheck" "--host-rustcflags" "-Crpath -O -Zunstable-options  -Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "--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" "5.0.0\n" "--system-llvm" "--cc" "cc" "--cxx" "c++" "--cflags" "-ffunction-sections -fdata-sections -fPIC -m64" "--llvm-components" "aarch64 aarch64asmparser aarch64asmprinter aarch64codegen aarch64desc aarch64disassembler aarch64info aarch64utils all all-targets amdgpu amdgpuasmparser amdgpuasmprinter amdgpucodegen amdgpudesc amdgpudisassembler amdgpuinfo amdgpuutils analysis arm armasmparser armasmprinter armcodegen armdesc armdisassembler arminfo asmparser asmprinter binaryformat bitreader bitwriter bpf bpfasmprinter bpfcodegen bpfdesc bpfdisassembler bpfinfo codegen core coroutines coverage debuginfocodeview debuginfodwarf debuginfomsf debuginfopdb demangle dlltooldriver engine executionengine globalisel hexagon hexagonasmparser hexagoncodegen hexagondesc hexagondisassembler hexagoninfo instcombine instrumentation interpreter ipo irreader lanai lanaiasmparser lanaiasmprinter lanaicodegen lanaidesc lanaidisassembler lanaiinfo libdriver lineeditor linker lto mc mcdisassembler mcjit mcparser mips mipsasmparser mipsasmprinter mipscodegen mipsdesc mipsdisassembler mipsinfo mirparser msp430 msp430asmprinter msp430codegen msp430desc msp430info native nativecodegen nvptx nvptxasmprinter nvptxcodegen nvptxdesc nvptxinfo objcarcopts object objectyaml option orcjit passes powerpc powerpcasmparser powerpcasmprinter powerpccodegen powerpcdesc powerpcdisassembler powerpcinfo profiledata runtimedyld scalaropts selectiondag sparc sparcasmparser sparcasmprinter sparccodegen sparcdesc sparcdisassembler sparcinfo support symbolize systemz systemzasmparser systemzasmprinter systemzcodegen systemzdesc systemzdisassembler systemzinfo tablegen target transformutils vectorize x86 x86asmparser x86asmprinter x86codegen x86desc x86disassembler x86info x86utils xcore xcoreasmprinter xcorecodegen xcoredesc xcoredisassembler xcoreinfo" "--llvm-cxxflags" "-I/usr/lib/llvm-5.0/include -std=c++0x -fuse-ld=gold -Wl,--no-keep-files-mapped -Wl,--no-map-whole-files -fPIC -fvisibility-inlines-hidden -Werror=date-time -std=c++11 -Wall -W -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wno-maybe-uninitialized -Wdelete-non-virtual-dtor -Wno-comment -ffunction-sections -fdata-sections -O2 -DNDEBUG -g1  -fno-exceptions -DLLVM_BUILD_GLOBAL_ISEL -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS" "--ar" "ar" "--adb-path" "adb" "--adb-test-dir" "/data/tmp/work" "--android-cross-path" "" "--color" "always"
[01:24:24] 
[01:24:24] 
[01:24:24] failed to run: /checkout/obj/build/bootstrap/debug/bootstrap test
[01:24:24] Build completed unsuccessfully in 0:39:06
[01:24:24] Build completed unsuccessfully in 0:39:06
[01:24:24] Makefile:58: recipe for target 'check' failed
[01:24:24] make: *** [check] Error 1
travis_time:end:0e907c58:start=1543868546047406012,finish=1543868546347785603,duration=300379591
The command "date && (curl -fs --head https://google.com | grep ^Date: | sed 's/Date: //g' || true)
" exited with 0.
travis_fold:start:after_failure.1

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)

}
}

fn camel_case(string: &str) -> String {

This comment has been minimized.

@eddyb

eddyb Dec 3, 2018

Member

I don't think we should do this. We already use the snake_case query name for struct / enum variant names, it's just dep nodes that are different because they started outside of the query system.

One (significant?) advantage of not changing the case of query names, at all, is greppability: type_of is type_of everywhere the query is mentioned, not TypeOf in some places.

cc @nikomatsakis

This comment has been minimized.

@Zoxc

Zoxc Dec 7, 2018

Contributor

That only really matters to incremental tests though. I'm not sure I actually want them to show up in search results =P

@petrochenkov

This comment has been minimized.

Contributor

petrochenkov commented Dec 3, 2018

Perhaps I didn't work with queries enough, but I don't understand what's the point of the change and why is this an improvement.

@eddyb

This comment has been minimized.

Member

eddyb commented Dec 4, 2018

@petrochenkov This is pretty much just replacing a macro_rules macro (define_queries!) with a proc macro that has nicer (and simpler) input syntax.

The PR is more confusing atm though, because it kept both macros and daisy-chained them, to allow gradually moving from the old one to the new one.

@@ -218,7 +218,7 @@ define_queries! { <'tcx>
Each line of the macro defines one query. The name is broken up like this:

```
[] fn type_of: TypeOfItem(DefId) -> Ty<'tcx>,
[] fn type_of: TypeOf(DefId) -> Ty<'tcx>,
^^ ^^^^^^^ ^^^^^^^^^^ ^^^^^ ^^^^^^^^

This comment has been minimized.

@eddyb

eddyb Dec 4, 2018

Member

These markers were not updated.

@Zoxc

This comment has been minimized.

Contributor

Zoxc commented Dec 7, 2018

I forgot to include syntax for QueryDescription:

impl<'tcx> QueryDescription<'tcx> for queries::type_op_prove_predicate<'tcx> {
    fn describe(_tcx: TyCtxt<'_, '_, '_>, goal: CanonicalTypeOpProvePredicateGoal<'tcx>)
                -> Cow<'static, str> {
        format!("evaluating `type_op_prove_predicate` `{:?}`", goal).into()
    }
}

Anyone have some good ideas for that?

@eddyb

This comment has been minimized.

Member

eddyb commented Dec 7, 2018

I'd say something like this:

description("evaluating `type_op_prove_predicate` `{:?}`", goal)
@Zoxc

This comment has been minimized.

Contributor

Zoxc commented Dec 7, 2018

@eddyb That looks very unbound.

How about:

query type_of(DefId) -> Ty<'tcx> {
 	"evaluating `finding type of `{:?}`", $key
}
@mark-i-m

This comment has been minimized.

Contributor

mark-i-m commented Dec 7, 2018

Why not use a doc comment?

@eddyb

This comment has been minimized.

Member

eddyb commented Dec 7, 2018

@mark-i-m Literally this?

/// "finding type of `{:?}`", $key`

Or something neater? Maybe like this:

/// finding type of `{key:?}`

@Zoxc Zoxc force-pushed the Zoxc:query-macro branch from 76c53a7 to b7c78b4 Dec 7, 2018

@rust-highfive

This comment has been minimized.

Collaborator

rust-highfive commented Dec 7, 2018

The job x86_64-gnu-llvm-5.0 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.
travis_time:end:06b4ad44:start=1544220626755604741,finish=1544220629324912993,duration=2569308252
$ git checkout -qf FETCH_HEAD
travis_fold:end:git.checkout

Encrypted environment variables have been removed for security reasons.
See https://docs.travis-ci.com/user/pull-requests/#Pull-Requests-and-Security-Restrictions
$ export SCCACHE_BUCKET=rust-lang-ci-sccache2
$ export SCCACHE_REGION=us-west-1
Setting environment variables from .travis.yml
$ export IMAGE=x86_64-gnu-llvm-5.0
---
150936 ./.git
150384 ./obj/build/bootstrap/debug/incremental
135392 ./.git/modules
135388 ./.git/modules/src
134792 ./obj/build/bootstrap/debug/incremental/bootstrap-2oigu19tl6bg6
134788 ./obj/build/bootstrap/debug/incremental/bootstrap-2oigu19tl6bg6/s-f7dp823a6b-16jhp2j-n62axo8kpki7
107888 ./obj/build/x86_64-unknown-linux-gnu/stage0/lib/rustlib/x86_64-unknown-linux-gnu/codegen-backends
107420 ./src/tools/lldb
95116 ./src/tools/cl

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)

@Zoxc Zoxc force-pushed the Zoxc:query-macro branch from b7c78b4 to 4ece386 Dec 7, 2018

@rust-highfive

This comment has been minimized.

Collaborator

rust-highfive commented Dec 8, 2018

The job mingw-check 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.
travis_time:end:05b801f8:start=1544224442596761929,finish=1544224512640402127,duration=70043640198
$ git checkout -qf FETCH_HEAD
travis_fold:end:git.checkout

Encrypted environment variables have been removed for security reasons.
See https://docs.travis-ci.com/user/pull-requests/#Pull-Requests-and-Security-Restrictions
$ export SCCACHE_BUCKET=rust-lang-ci-sccache2
$ export SCCACHE_REGION=us-west-1
Setting environment variables from .travis.yml
$ export IMAGE=mingw-check
---
[00:07:26] configure: build.locked-deps    := True
[00:07:26] configure: llvm.ccache          := sccache
[00:07:26] configure: build.cargo-native-static := True
[00:07:26] configure: dist.missing-tools   := True
[00:07:26] configure: build.configure-args := ['--enable-sccache', '--disable-manage-submodu ...
[00:07:26] configure: writing `config.toml` in current directory
[00:07:26] configure: 
[00:07:26] configure: run `python /checkout/x.py --help`
[00:07:26] configure: 
---
[00:12:27]     Checking rustc-demangle v0.1.9
[00:12:27]     Checking num_cpus v1.8.0
[00:12:31]     Checking memmap v0.6.2
[00:12:31]    Compiling rustc_llvm v0.0.0 (/checkout/src/librustc_llvm)
[00:12:33] error[E0463]: can't find crate for `rustc_macros` which `rustc` depends on
[00:12:33]    |
[00:12:33] 45 | #[macro_use] extern crate rustc;
[00:12:33]    |              ^^^^^^^^^^^^^^^^^^^ can't find crate
[00:12:33] 
[00:12:33] 
[00:12:33] error: aborting due to previous error
[00:12:33] 
[00:12:33] For more information about this error, try `rustc --explain E0463`.
[00:12:33] error: Could not compile `rustc_codegen_llvm`.
[00:12:33] 
[00:12:33] To learn more, run the command again with --verbose.
[00:12:33] command did not execute successfully: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0/bin/cargo" "check" "--target" "i686-pc-windows-gnu" "-j" "4" "--release" "--locked" "--color" "always" "--manifest-path" "/checkout/src/librustc_codegen_llvm/Cargo.toml" "--message-format" "json"
[00:12:33] travis_fold:start:stage0-rustc_codegen_llvm
travis_time:start:stage0-rustc_codegen_llvm
failed to run: /checkout/obj/build/bootstrap/debug/bootstrap check --target=i686-pc-windows-gnu --host=i686-pc-windows-gnu
[00:12:33] Build completed unsuccessfully in 0:03:56
---
travis_time:end:100940bc:start=1544225275217129397,finish=1544225275222627296,duration=5497899
travis_fold:end:after_failure.3
travis_fold:start:after_failure.4
travis_time:start:04205a02
$ ln -s . checkout && for CORE in obj/cores/core.*; do EXE=$(echo $CORE | sed 's|obj/cores/core\.[0-9]*\.!checkout!\(.*\)|\1|;y|!|/|'); if [ -f "$EXE" ]; then printf travis_fold":start:crashlog\n\033[31;1m%s\033[0m\n" "$CORE"; gdb --batch -q -c "$CORE" "$EXE" -iex 'set auto-load off' -iex 'dir src/' -iex 'set sysroot .' -ex bt -ex q; echo travis_fold":"end:crashlog; fi; done || true
travis_fold:end:after_failure.4
travis_fold:start:after_failure.5
travis_time:start:04627458
travis_time:start:04627458
$ cat ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers || true
cat: ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers: No such file or directory
travis_fold:end:after_failure.5
travis_fold:start:after_failure.6
travis_time:start:099010d8
$ dmesg | grep -i kill

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)

@Zoxc

This comment has been minimized.

Contributor

Zoxc commented Dec 8, 2018

I don't think using comments is a good idea. You'd want to use those to document the queries. Also it's very surprising that comments are executable.

@rust-highfive

This comment has been minimized.

Collaborator

rust-highfive commented Dec 8, 2018

The job mingw-check 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.
travis_time:end:00c700f5:start=1544278669563959679,finish=1544278723777822350,duration=54213862671
$ git checkout -qf FETCH_HEAD
travis_fold:end:git.checkout

Encrypted environment variables have been removed for security reasons.
See https://docs.travis-ci.com/user/pull-requests/#Pull-Requests-and-Security-Restrictions
$ export SCCACHE_BUCKET=rust-lang-ci-sccache2
$ export SCCACHE_REGION=us-west-1
Setting environment variables from .travis.yml
$ export IMAGE=mingw-check
---
[00:07:32] configure: build.locked-deps    := True
[00:07:32] configure: llvm.ccache          := sccache
[00:07:32] configure: build.cargo-native-static := True
[00:07:32] configure: dist.missing-tools   := True
[00:07:32] configure: build.configure-args := ['--enable-sccache', '--disable-manage-submodu ...
[00:07:32] configure: writing `config.toml` in current directory
[00:07:32] configure: 
[00:07:32] configure: run `python /checkout/x.py --help`
[00:07:32] configure: 
---
[00:12:39]     Checking rustc_save_analysis v0.0.0 (/checkout/src/librustc_save_analysis)
[00:12:39]     Checking rustc_codegen_ssa v0.0.0 (/checkout/src/librustc_codegen_ssa)
[00:12:44]     Checking rustc-main v0.0.0 (/checkout/src/rustc)
[00:12:45]     Finished release [optimized] target(s) in 3m 21s
[00:12:45] thread 'main' panicked at 'failed to copy `/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-rustc/release/deps/librustc_macros-9f012a3c4a8560db.so` to `/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-sysroot/lib/rustlib/x86_64-unknown-linux-gnu/lib/librustc_macros-9f012a3c4a8560db.so`: No such file or directory (os error 2)', src/bootstrap/lib.rs:1180:17
[00:12:45] travis_fold:end:stage0-rustc

[00:12:45] travis_time:end:stage0-rustc:start=1544279296114616927,finish=1544279497326681879,duration=201212064952

---
travis_time:end:09b0810d:start=1544279498047769029,finish=1544279498053695603,duration=5926574
travis_fold:end:after_failure.3
travis_fold:start:after_failure.4
travis_time:start:0bee4ee4
$ ln -s . checkout && for CORE in obj/cores/core.*; do EXE=$(echo $CORE | sed 's|obj/cores/core\.[0-9]*\.!checkout!\(.*\)|\1|;y|!|/|'); if [ -f "$EXE" ]; then printf travis_fold":start:crashlog\n\033[31;1m%s\033[0m\n" "$CORE"; gdb --batch -q -c "$CORE" "$EXE" -iex 'set auto-load off' -iex 'dir src/' -iex 'set sysroot .' -ex bt -ex q; echo travis_fold":"end:crashlog; fi; done || true
travis_fold:end:after_failure.4
travis_fold:start:after_failure.5
travis_time:start:0914b014
travis_time:start:0914b014
$ cat ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers || true
cat: ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers: No such file or directory
travis_fold:end:after_failure.5
travis_fold:start:after_failure.6
travis_time:start:1a96e650
$ dmesg | grep -i kill

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)

@Zoxc Zoxc force-pushed the Zoxc:query-macro branch from 9665df4 to d7d8a44 Dec 8, 2018

@Zoxc

This comment has been minimized.

Contributor

Zoxc commented Dec 8, 2018

Maybe this?

query type_of(key: DefId) -> Ty<'tcx> {
	cache { key.is_local() },
	description { "evaluating `finding type of `{:?}`", key },
	fatal_cycle,
	eval_always,
}
wip
@rust-highfive

This comment has been minimized.

Collaborator

rust-highfive commented Dec 8, 2018

The job x86_64-gnu-llvm-5.0 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.
travis_time:end:00d4a60c:start=1544289288835307124,finish=1544289377476586589,duration=88641279465
$ git checkout -qf FETCH_HEAD
travis_fold:end:git.checkout

Encrypted environment variables have been removed for security reasons.
See https://docs.travis-ci.com/user/pull-requests/#Pull-Requests-and-Security-Restrictions
$ export SCCACHE_BUCKET=rust-lang-ci-sccache2
$ export SCCACHE_REGION=us-west-1
Setting environment variables from .travis.yml
$ export IMAGE=x86_64-gnu-llvm-5.0
---
[00:12:57]    Compiling rustc_typeck v0.0.0 (/checkout/src/librustc_typeck)
[00:12:58] error[E0603]: trait `QueryConfig` is private
[00:12:58]   --> src/librustc_metadata/cstore_impl.rs:18:23
[00:12:58]    |
[00:12:58] 18 | use rustc::ty::query::QueryConfig;
[00:12:58] 
[00:12:59] error: aborting due to previous error
[00:12:59] 
[00:12:59] For more information about this error, try `rustc --explain E0603`.
[00:12:59] For more information about this error, try `rustc --explain E0603`.
[00:12:59] error: Could not compile `rustc_metadata`.
[00:12:59] warning: build failed, waiting for other jobs to finish...
[00:16:19] error: build failed
[00:16:19] command did not execute successfully: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0/bin/cargo" "build" "--target" "x86_64-unknown-linux-gnu" "-j" "4" "--release" "--locked" "--color" "always" "--features" "" "--manifest-path" "/checkout/src/rustc/Cargo.toml" "--message-format" "json"
[00:16:19] expected success, got: exit code: 101
[00:16:19] failed to run: /checkout/obj/build/bootstrap/debug/bootstrap build
[00:16:19] Build completed unsuccessfully in 0:12:58
[00:16:19] make: *** [all] Error 1
[00:16:19] Makefile:28: recipe for target 'all' failed
The command "stamp sh -x -c "$RUN_SCRIPT"" exited with 2.
travis_time:start:1192bcea
$ date && (curl -fs --head https://google.com | grep ^Date: | sed 's/Date: //g' || true)
Sat Dec  8 17:32:45 UTC 2018
---
travis_time:end:1f624874:start=1544290366254776286,finish=1544290366259613716,duration=4837430
travis_fold:end:after_failure.3
travis_fold:start:after_failure.4
travis_time:start:0eacacbd
$ ln -s . checkout && for CORE in obj/cores/core.*; do EXE=$(echo $CORE | sed 's|obj/cores/core\.[0-9]*\.!checkout!\(.*\)|\1|;y|!|/|'); if [ -f "$EXE" ]; then printf travis_fold":start:crashlog\n\033[31;1m%s\033[0m\n" "$CORE"; gdb --batch -q -c "$CORE" "$EXE" -iex 'set auto-load off' -iex 'dir src/' -iex 'set sysroot .' -ex bt -ex q; echo travis_fold":"end:crashlog; fi; done || true
travis_fold:end:after_failure.4
travis_fold:start:after_failure.5
travis_time:start:1d987250
travis_time:start:1d987250
$ cat ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers || true
cat: ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers: No such file or directory
travis_fold:end:after_failure.5
travis_fold:start:after_failure.6
travis_time:start:13ff22af
$ dmesg | grep -i kill

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)

@Zoxc Zoxc force-pushed the Zoxc:query-macro branch from 5230ab4 to 5cc63b9 Dec 8, 2018

@rust-highfive

This comment has been minimized.

Collaborator

rust-highfive commented Dec 8, 2018

The job x86_64-gnu-llvm-5.0 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.
travis_time:end:01822929:start=1544291897429642780,finish=1544291974559362427,duration=77129719647
$ git checkout -qf FETCH_HEAD
travis_fold:end:git.checkout

Encrypted environment variables have been removed for security reasons.
See https://docs.travis-ci.com/user/pull-requests/#Pull-Requests-and-Security-Restrictions
$ export SCCACHE_BUCKET=rust-lang-ci-sccache2
$ export SCCACHE_REGION=us-west-1
Setting environment variables from .travis.yml
$ export IMAGE=x86_64-gnu-llvm-5.0
---
[00:45:27] .................................................................................................... 500/5131
[00:45:30] ..............................i..................................................................... 600/5131
[00:45:34] .................................................................................................... 700/5131
[00:45:39] .................................................................................................... 800/5131
[00:45:43] .i............F..i.................................................................................. 900/5131
[00:45:47] ........................iiiii....................................................................... 1000/5131
[00:45:51] .................................................................................................... 1200/5131
[00:45:54] .................................................................................................... 1300/5131
[00:45:54] .................................................................................................... 1300/5131
[00:45:56] ..........F......................................................................................... 1400/5131
[00:46:01] ...........................i....................................................................i... 1600/5131
[00:46:01] ...........................i....................................................................i... 1600/5131
[00:46:05] .........................................................F.......................................... 1700/5131
[00:46:08] .......................................................................F............................ 1800/5131
[00:46:14] .....................................i.............................................................. 2000/5131
[00:46:18] .................................................................................................... 2100/5131
[00:46:21] .................................................................................................... 2200/5131
[00:46:25] .................................................................................................... 2300/5131
[00:46:25] .................................................................................................... 2300/5131
[00:46:29] .................................................................................................... 2400/5131
[00:46:32] ........................F........................................................................... 2500/5131
[00:46:40] .................................................................................................... 2700/5131
[00:46:44] .................................................................................................... 2800/5131
[00:46:46] .................................................................................................... 2900/5131
[00:46:50] .................................................................................................... 3000/5131
---
[00:47:13] ..i................................................................................................. 3900/5131
[00:47:18] .................................................................................................... 4000/5131
[00:47:23] .................................................................................................... 4100/5131
[00:47:26] .................................................................................................... 4200/5131
[00:47:29] ..........................F.............................F........................................... 4300/5131
[00:47:34] ..i................................................................................................. 4400/5131
[00:47:41] .................................................................................................... 4600/5131
[00:47:45] .......................................................................................i............ 4700/5131
[00:47:48] .................................................................................................... 4800/5131
[00:47:51] .................................................................................................... 4900/5131
[00:47:51] .................................................................................................... 4900/5131
[00:47:54] .................................................................................................... 5000/5131
[00:47:56] ......................................................................i............................. 5100/5131
t_start":19,"highlight_end":22}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"...which again requires finding type of Foo::X, completing the cycle","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0391]: cycle detected when finding type of Foo::X\n  --> /checkout/src/test/ui/cycle-trait/cycle-trait-default-type-trait.rs:14:19\n   |\nLL | trait Foo<X = Box<Foo>> {\n   |                   ^^^\n   |\n   = note: ...which again requires finding type of Foo::X, completing the cycle\n\n"}
[00:47:57] {"message":"aborting due to previous error","code":null,"level":"error","spans":[],"children":[],"rendered":"error: aborting due to previous error\n\n"}
[00:47:57] {"message":"For more information about this error, try `rustc --explain E0391`.","code":null,"level":"","spans":[],"children":[],"rendered":"For more information about this error, try `rustc --explain E0391`.\n"}
[00:47:57] ------------------------------------------
[00:47:57] 
[00:47:57] thread '[ui] ui/cycle-trait/cycle-trait-default-type-trait.rs' panicked at 'explicit panic', src/tools/compiletest/src/runtest.rs:3252:9
[00:47:57] note: Run with `RUST_BACKTRACE=1` for a backtrace.
[00:47:57] note: Run with `RUST_BACKTRACE=1` for a backtrace.
[00:47:57] 
[00:47:57] ---- [ui] ui/existential_types/no_inferrable_concrete_type.rs stdout ----
[00:47:57] diff of stderr:
[00:47:57] 
[00:47:57] - error[E0391]: cycle detected when processing `Foo`
[00:47:57] + error[E0391]: cycle detected when finding type of Foo
[00:47:57] 2   --> $DIR/no_inferrable_concrete_type.rs:16:1
[00:47:57] 3    |
[00:47:57] 4 LL |rt":16,"highlight_end":26}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}}}],"children":[{"message":"...which requires processing `cycle1`...","code":null,"level":"note","spans":[{"file_name":"/checkout/src/test/ui/impl-trait/auto-trait-leak.rs","byte_start":739,"byte_end":764,"line_start":24,"line_end":24,"column_start":1,"column_end":26,"is_primary":true,"text":[{"text":"fn cycle1() -> impl Clone {","highlight_start":1,"highlight_end":26}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null},{"message":"...which requires evaluating trait selection obligation `impl std::clone::Clone: std::marker::Send`...","code":null,"level":"note","spans":[{"file_name":"/checkout/src/test/ui/impl-trait/auto-trait-leak.rs","byte_start":0,"byte_end":0,"line_start":1,"line_end":1,"column_start":1,"column_end":1,"is_primary":true,"text":[{"text":"// Copyright 2016 The Rust Project Developers. See the COPYRIGHT","highlight_start":1,"highlight_end":1}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null},{"message":"...which requires finding type of cycle2::{{impl-Trait}}...","code":null,"level":"note","spans":[{"file_name":"/checkout/src/test/ui/impl-trait/auto-trait-leak.rs","byte_start":953,"byte_end":963,"line_start":33,"line_end":33,"column_start":16,"column_end":26,"is_primary":true,"text":[{"text":"fn cycle2() -> impl Clone {","highlight_start":16,"highlight_end":26}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":{t":"// Copyright 2016 The Rust Project Developers. See the COPYRIGHT","highlight_start":1,"highlight_end":1}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null},{"message":"...which again requires finding type of cycle1::{{impl-Trait}}, completing the cycle","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0391]: cycle detected when finding type of cycle1::{{impl-Trait}}\n  --> /checkout/src/test/ui/impl-trait/auto-trait-leak.rs:24:16\n   |\nLL | fn cycle1() -> impl Clone {\n   |                ^^^^^^^^^^\n   |\nnote: ...which requires processing `cycle1`...\n  --> /checkout/src/test/ui/impl-trait/auto-trait-leak.rs:24:1\n   |\nLL | fn cycle1() -> impl Clone {\n   | ^^^^^^^^^^^^^^^^^^^^^^^^^\nnote: ...which requires evaluating trait selection obligation `impl std::clone::Clone: std::marker::Send`...\nnote: ...which requires finding type of cycle2::{{impl-Trait}}...\n  --> /checkout/src/test/ui/impl-trait/auto-trait-leak.rs:33:16\n   |\nLL | fn cycle2() -> impl Clone {\n   |                ^^^^^^^^^^\nnote: ...which requires processing `cycle2`...\n  --> /checkout/src/test/ui/impl-trait/auto-trait-leak.rs:33:1\n   |\nLL | fn cycle2() -> impl Clone {\n   | ^^^^^^^^^^^^^^^^^^^^^^^^^\nnote: ...which requires evaluating trait selection obligation `impl std::clone::Clone: std::marker::Send`...\n   = note: ...which again requires finding type of cycle1::{{impl-Trait}}, completing the cycle\n\n"}
[00:47:57] {"message":"cycle detected when finding type of cycle1::{{impl-Trait}}","code":{"code":"E0391","explanation":"\nThis error indicates that some types or traits depend on each other\nand therefore cannot be constructed.\n\nThe following example contains a circular dependency between two traits:\n\n```compile_fail,E0391\ntrait FirstTrait : SecondTrait {\n\n}\n\ntrait SecondTrait : FirstTrait {\n\n}\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/impl-trait/auto-trait-leak.rs","byte_start":754,"byte_end":764,"line_start":24,"line_end":24,"column_start":16,"column_end":26,"is_primary":true,"text":[{"text":"fn cycle1() -> impl Clone {","highlight_start":16,"highlight_end":26}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":{"span":{"file_name":"/checkout/src/test/ui/impl-trait/auto-trait-leak.rs","byte_start":754,"byte_end":764,"line_start":24,"line_end":24,"column_start":16,"column_end":26,"is_primary":false,"text":[{"text":"fn cycle1() -> impl Clone {","highlight_start":16,"highlight_end":26}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null},"macro_decl_name":"desugaring of `existential type`","def_site_span":{"file_name":"/checkout/src/test/ui/impl-trait/auto-trait-leak.rs","byte_start":754,"byte_end":764,"line_start":24,"line_end":24,"column_start":16,"column_end":26,"is_primary":false,"text":[{"text":"fn cycle1() -> impl Clone {","highlight_start":16,"highlight_end":26}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}}}],"children":[{"message":"...which requires processing `cycle1`...","code":null,"level":"note","spans":[{"file_name":"/checkout/src/test/ui/impl-trait/auto-trait-leak.rs","byte_st_replacement":null,"suggestion_applicability":null,"expansion":null},"macro_decl_name":"desugaring of `existential type`","def_site_span":{"file_name":"/checkout/src/test/ui/impl-trait/auto-trait-leak.rs","byte_start":953,"byte_end":963,"line_start":33,"line_end":33,"column_start":16,"column_end":26,"is_primary":false,"text":[{"text":"fn cycle2() -> impl Clone {","highlight_start":16,"highlight_end":26}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}}}],"children":[],"rendered":null},{"message":"...which requires processing `cycle2`...","code":null,"level":"note","spans":[{"file_name":"/checkout/src/test/ui/impl-trait/auto-trait-leak.rs","byte_start":938,"byte_end":963,"line_start":33,"line_end":33,"column_start":1,"column_end":26,"is_primary":true,"text":[{"text":"fn cycle2() -> impl Clone {","highlight_start":1,"highlight_end":26}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null},{"message":"...which again requires finding type of cycle1::{{impl-Trait}}, completing the cycle","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0391]: cycle detected when finding type of cycle1::{{impl-Trait}}\n  --> /checkout/src/test/ui/impl-trait/auto-trait-leak.rs:24:16\n   |\nLL | fn cycle1() -> impl Clone {\n   |                ^^^^^^^^^^\n   |\nnote: ...which requires processing `cycle1`...\n  --> /checkout/src/test/ui/impl-trait/auto-trait-leak.rs:24:1\n   |\nLL | fn cycle1() -> impl Clone {\n   | ^^^^^^^^^^^^^^^^^^^^^^^^^\nnote: ...which requires evaluating trait selection obliga:57] To update references, rerun the tests and pass the `--bless` flag
[00:47:57] To only update this specific test, also pass `--test-args infinite/infinite-vec-type-recursion.rs`
[00:47:57] error: 1 errors occurred comparing output.
[00:47:57] status: exit code: 1
[00:47:57] status: exit code: 1
[00:47:57] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/infinite/infinite-vec-type-recursion.rs" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/infinite/infinite-vec-type-recursion/a" "-Crpath" "-O" "-Zunstable-options" "-Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/infinite/infinite-vec-type-recursion/auxiliary" "-A" "unused"
[00:47:57] ------------------------------------------
[00:47:57] 
[00:47:57] ------------------------------------------
[00:47:57] stderr:
[00:47:57] stderr:
[00:47:57] ------------------------------------------
[00:47:57] {"message":"cycle detected when finding type of x","code":{"code":"E0391","explanation":"\nThis error indicates that some types or traits depend on each other\nand therefore cannot be constructed.\n\nThe following example contains a circular dependency between two traits:\n\n```compile_fail,E0391\ntrait FirstTrait : SecondTrait {\n\n}\n\ntrait SecondTrait : FirstTrait {\n\n}\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/infinite/infinite-vec-type-recursion.rs","byte_start":480,"byte_end":481,"line_start":11,"line_end":11,"columROR cycle detected
[00:47:57] 5    |                              ^^^^^^^^^^
[00:47:57] 6    |
[00:47:57] 6    |
[00:47:57] - note: ...which requires processing `DefaultFoo`...
[00:47:57] + note: ...which requires finding type of DefaultFoo...
[00:47:57] 9    |
[00:47:57] 9    |
[00:47:57] 10 LL | type DefaultFoo = Foo;
[00:47:57] 11    |                   ^^^
[00:47:57] 11    |                   ^^^
[00:47:57] -    = note: ...which again requires processing `Foo::T`, completing the cycle
[00:47:57] +    = note: ...which again requires finding type of Foo::T, completing the cycle
[00:47:57] 14 error: aborting due to previous error
[00:47:57] 15 
[00:47:57] 
[00:47:57] 
[00:47:57] 
[00:47:57] The actual stderr differed from the expected stderr.
[00:47:57] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/issues/issue-34373/issue-34373.stderr
[00:47:57] To update references, rerun the tests and pass the `--bless` flag
[00:47:57] To only update this specific test, also pass `--test-args issues/issue-34373.rs`
[00:47:57] error: 1 errors occurred comparing output.
[00:47:57] status: exit code: 1
[00:47:57] status: exit code: 1
[00:47:57] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/issues/issue-34373.rs" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/issues/issue-34373/a" "-Crpath" "-O" "-Zunstable-options" "-Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/issues/issue-34373/auxiliary" "-A" "unused"
[00:47:57] ------------------------------------------
[00:47:57] 
[00:47:57] ------------------------------------------
[00:47:57] stderr:
[00:47:57] stderr:
[00:47:57] ------------------------------------------
[00:47:57] {"message":"cycle detected when finding type of Foo::T","code":{"code":"E0391","explanation":"\nThis error indicates that some types or traits depend on each other\nand therefore cannot be constructed.\n\nThe following example contains a circular dependency between two traits:\n\n```compile_fail,E0391\ntrait FirstTrait : SecondTrait {\n\n}\n\ntrait SecondTrait : FirstTrait {\n\n}\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-34373.rs","byte_start":557,"byte_end":567,"line_start":17,"line_end":17,"column_start":30,"column_end":40,"is_primary":true,"text":[{"text":"pub struct Foo<T = Box<Trait<DefaultFoo>>>;  //~ ERROR cycle detected","highlight_start":30,"highlight_end":40}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"...which requires finding type of DefaultFoo...","code":null,"level":"note","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-34373.rs","byte_start":616,"byte_end":619,"line_start":18,"line_end":18,"column_start":19,"column_end":22,"is_primary":true,"text":[{"text":"type DefaultFoo = Foo;","highlight_start":19,"highlight_end":22}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null},{"message":"...which again requires finding type of Foo::T, completing the cycle       ^^^^
[00:47:57] 6    |
[00:47:57] -    = note: ...which again requires processing `<impl at $DIR/issue-23305.rs:15:1: 15:20>`, completing the cycle
[00:47:57] +    = note: ...which again requires finding type of <impl at $DIR/issue-23305.rs:15:1: 15:20>, completing the cycle
[00:47:57] 9 error: aborting due to previous error
[00:47:57] 10 
[00:47:57] 
[00:47:57] 
[00:47:57] 
[00:47:57] The actual stderr differed from the expected stderr.
[00:47:57] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/resolve/issue-23305/issue-23305.stderr
[00:47:57] To update references, rerun the tests and pass the `--bless` flag
[00:47:57] To only update this specific test, also pass `--test-args resolve/issue-23305.rs`
[00:47:57] error: 1 errors occurred comparing output.
[00:47:57] status: exit code: 1
[00:47:57] status: exit code: 1
[00:47:57] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/resolve/issue-23305.rs" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/resolve/issue-23305/a" "-Crpath" "-O" "-Zunstable-options" "-Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/resolve/issue-23305/auxiliary" "-A" "unused"
[00:47:57] ------------------------------------------
[00:47:57] 
[00:47:57] ------------------------------------------
[00:47:57] stderr:
[00:47:57] stderr:
[00:47:57] ------------------------------------------
[00:47:57] {"message":"cycle detected when finding type of <impl at /checkout/src/test/ui/resolve/issue-23305.rs:15:1: 15:20>","code":{"code":"E0391","explanation":"\nThis error indicates that some types or traits depend on each other\nand therefore cannot be constructed.\n\nThe following example contains a circular dependency between two traits:\n\n```compile_fail,E0391\ntrait FirstTrait : SecondTrait {\n\n}\n\ntrait SecondTrait : FirstTrait {\n\n}\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/resolve/issue-23305.rs","byte_start":530,"byte_end":534,"line_start":15,"line_end":15,"column_start":12,"column_end":16,"is_primary":true,"text":[{"text":"impl ToNbt<Self> {}","highlight_start":12,"highlight_end":16}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"...which again requires finding type of <impl at /checkout/src/test/ui/resolve/issue-23305.rs:15:1: 15:20>, completing the cycle","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0391]: cycle detected when finding type of <impl at /checkout/src/test/ui/resolve/issue-23305.rs:15:1: 15:20>\n  --> /checkout/src/test/ui/resolve/issue-23305.rs:15:12\n   |\nLL | impl ToNbt<Self> {}\n   |            ^^^^\n   |\n   = note: ...which again requires finding type of <impl at /checkout/src/test/ui/resolve/issue-23305.rs:15:1: 15:20>, completing the cycle\n\n"}
[00:47:57] {"message":"aborting due to previous error","code":null,"level":"error","spans":[],"children":[],"rendered":"error: aborting due to previous error\n\n"}
[00:47:57] {"message":"For more information about this error, try `rustc --e -    = note: ...which again requires processing `<impl at $DIR/resolve-self-in-impl.rs:25:1: 25:23>`, completing the cycle
[00:47:57] +    = note: ...which again requires finding type of <impl at $DIR/resolve-self-in-impl.rs:25:1: 25:23>, completing the cycle
[00:47:57] 16 
[00:47:57] - error[E0391]: cycle detected when processing `<impl at $DIR/resolve-self-in-impl.rs:26:1: 26:13>`
[00:47:57] + error[E0391]: cycle detected when finding type of <impl at $DIR/resolve-self-in-impl.rs:26:1: 26:13>
[00:47:57] 19    |
[00:47:57] 19    |
[00:47:57] 20 LL | impl Self {} //~ ERROR cycle detected
[00:47:57] 21    |      ^^^^
[00:47:57] 22    |
[00:47:57] 22    |
[00:47:57] -    = note: ...which again requires processing `<impl at $DIR/resolve-self-in-impl.rs:26:1: 26:13>`, completing the cycle
[00:47:57] +    = note: ...which again requires finding type of <impl at $DIR/resolve-self-in-impl.rs:26:1: 26:13>, completing the cycle
[00:47:57] 24 
[00:47:57] - error[E0391]: cycle detected when processing `<impl at $DIR/resolve-self-in-impl.rs:27:1: 27:16>`
[00:47:57] + error[E0391]: cycle detected when finding type of <impl at $DIR/resolve-self-in-impl.rs:27:1: 27:16>
[00:47:57] 27    |
[00:47:57] 27    |
[00:47:57] 28 LL | impl S<Self> {} //~ ERROR cycle detected
[00:47:57] 29    |        ^^^^
[00:47:57] 30    |
[00:47:57] 30    |
[00:47:57] -    = note: ...which again requires processing `<impl at $DIR/resolve-self-in-impl.rs:27:1: 27:16>`, completing the cycle
[00:47:57] +    = note: ...which again requires finding type of <impl at $DIR/resolve-self-in-impl. on each other\nand therefore cannot be constructed.\n\nThe following example contains a circular dependency between two traits:\n\n```compile_fail,E0391\ntrait FirstTrait : SecondTrait {\n\n}\n\ntrait SecondTrait : FirstTrait {\n\n}\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/resolve/resolve-self-in-impl.rs","byte_start":820,"byte_end":824,"line_start":25,"line_end":25,"column_start":15,"column_end":19,"is_primary":true,"text":[{"text":"impl Tr for S<Self> {} //~ ERROR cycle detected","highlight_start":15,"highlight_end":19}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"...which again requires finding type of <impl at /checkout/src/test/ui/resolve/resolve-self-in-impl.rs:25:1: 25:23>, completing the cycle","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0391]: cycle detected when finding type of <impl at /checkout/src/test/ui/resolve/resolve-self-in-impl.rs:25:1: 25:23>\n  --> /checkout/src/test/ui/resolve/resolve-self-in-impl.rs:25:15\n   |\nLL | impl Tr for S<Self> {} //~ ERROR cycle detected\n   |               ^^^^\n   |\n   = note: ...which again requires finding type of <impl at /checkout/src/test/ui/resolve/resolve-self-in-impl.rs:25:1: 25:23>, completing the cycle\n\n"}
[00:47:57] {"message":"cycle detected when finding type of <impl at /checkout/src/test/ui/resolve/resolve-self-in-impl.rs:26:1: 26:13>","code":{"code":"E0391","explanation":"\nThis error indicates that some types or traits depend on each other\nand therefore cannot be constructed.\n\nThe following example containstravis_time:end:229a95bc:start=1544291982621764179,finish=1544294860400920281,duration=2877779156102
travis_time:start:00e8df37
$ date && (curl -fs --head https://google.com | grep ^Date: | sed 's/Date: //g' || true)
Sat Dec  8 18:47:40 UTC 2018
Sat, 08 Dec 2018 18:47:40 GMT
---
travis_time:end:1d0ae148:start=1544294861514957975,finish=1544294861523039949,duration=8081974
travis_fold:end:after_failure.4
travis_fold:start:after_failure.5
travis_time:start:213ad9de
$ cat ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers || true
cat: ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers: No such file or directory
travis_fold:end:after_failure.5
travis_fold:start:after_failure.6
travis_time:start:097d76f8
$ dmesg | grep -i kill

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)

fix
@bors

This comment has been minimized.

Contributor

bors commented Dec 8, 2018

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

@Zoxc

This comment has been minimized.

Contributor

Zoxc commented Dec 8, 2018

cc @alexcrichton for the build system changes

@alexcrichton

This comment has been minimized.

Member

alexcrichton commented Dec 9, 2018

I would personally prefer to hold off on landing this until a PR like #56447 lands which is a bare bones usage of procedural macros during the bootstrap. I haven't had a chance to really fully understand that and I'm not sure it's ready to go, and I think it'd be best if we figure out the procedural macro trickery necessary before we open the floodgates to all sorts of new macros

@Zoxc

This comment has been minimized.

Contributor

Zoxc commented Dec 9, 2018

@alexcrichton Well the build system changes there are not correct. Which is why I wanted you to look at the changes here. We can move them over to that PR and land that first though.

@alexcrichton

Ah ok, makes sense! The build system changes here look good to me (or at least not obviously wrong). I still have basically no idea how this works without updating the bootstrap compiler! I'm going to check this out locally and poke around it a bit too.

@@ -86,6 +88,7 @@ extern crate graphviz;
extern crate libc;
extern crate polonius_engine;
extern crate rustc_target;
#[macro_use] extern crate rustc_macros;

This comment has been minimized.

@alexcrichton

alexcrichton Dec 10, 2018

Member

FWIW wherever possible it'd be great to stop using #[macro_use] for new macro-based code

@alexcrichton

This comment has been minimized.

Member

alexcrichton commented Dec 10, 2018

Ok I've sat down with some build logs and I think I've figured this out. There's basically a whole slew of decisions, none of which were made to enable this, which are enabling this.

First up, some facts:

  • When compiling procedural macros, RUSTC_SNAPSHOT is always chosen. This is because there is no --target argument
  • For the rustc component of building, this env var points to the compiler in question, and it's not always hardcoded to the actual stage0 rustc binary (like I thought). This self.rustc(..) and self.rustc_libdir(..) both have special cases for the stage0 case (snapshot) - A, B

Next I want to explain what happens during the first compile. During the first compilation of the compiler the rustc_macros crate here must be linked against proc_macro. While building libstd/libtest we create a libproc_macro.rlib binary. This is entirely unused by rustc_macros! Instead due to the above we're using the stage0 (snapshot) compiler and linking against the proc_macro in the sysroot, which is the stage0 sysroot that we downloaded. This means that during the first compilation of the compiler, procedural macros are using the proc_macro crate from the original compiler, making it trivially compatible with the compiler as they're all compiled against it.

The second compilation is a bit different. We don't have any downloaded libraries to use and we're on our own. By the time we reach rustc_macros the libproc_macro.rlib file has again been compiled during libstd/libtest. This time, however, it's actually used when compiling rustc_macro as it's in the sysroot that we're using (as there's not two sysroots in stage1 unlike in stage0). The stage1 compiler then loads what it just compiled and runs it.


I believe this means that the first compilation of libproc_macro is basically inert. It could be full of panics and it doesn't matter. This also means that if we change the ABI of the structures in proc_macro it's ok. Only the stage1 compiler actually starts using it, so the stage1 compiler is expecting the new ABI and the proc_macro crate we build is providing the new ABI.

Finally, just to justify to myself, we do still need @eddyb's work on a "stable ABI" for proc_macro. If we didn't have that, then the stage1 compiler would have a stage0-defined ABI, but it may be compiling a new ABI which it's loading. Put another way, the stage0 and stage1 compiler disagree about the "Rust" ABI, but they agree on the "C" ABI, which is what we need.

So... actually I think this is it? I don't think there's anything else needed here, and we can land this at any time irrespective of updating the bootstrap compiler. It's all set up quite precariously but it at least works!

@@ -294,6 +287,13 @@ fn main() {
}
}

// Force all crates compiled by this compiler to (a) be unstable and (b)

This comment has been minimized.

@bjorn3

bjorn3 Dec 12, 2018

Contributor

Why is this moved?

[dependencies]
syn = { version = "0.15.22", features = ["full"] }
proc-macro2 = "0.4.24"
quote = "0.6.10"

This comment has been minimized.

@bjorn3

bjorn3 Dec 12, 2018

Contributor

Missing trailing newline

@alexcrichton

This comment has been minimized.

Member

alexcrichton commented Dec 12, 2018

One thing I've just thought of is that we may want to start out using procedural macros in rustc with something that's minimally invasive to rustc itself (aka easy to revert). It may take a few days to ensure that we distribute the compiler correctly and various tooling like rls/rustfmt/clippy/etc continue to work, so I just want to make sure that if we need to fix a bug and it takes awhile for whatever reason we don't leave nightlies inert for some time

@Zoxc

This comment has been minimized.

Contributor

Zoxc commented Dec 12, 2018

@alexcrichton Do we test cross compilation?

@alexcrichton

This comment has been minimized.

Member

alexcrichton commented Dec 12, 2018

We do sort of in the sense that we cross compile a lot of things, but we don't test cross compilation in the way that it looks to end users I think much. Or at least I think the ecosystem tests it a lot more than we do!

bors added a commit that referenced this pull request Dec 14, 2018

Auto merge of #56795 - Zoxc:serde-poc, r=alexcrichton
Start using serde_derive in a couple places in the compiler

This is #56447 with the build changes in #56462

r? @alexcrichton
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment