Repository: racer-rust/racer (language: rust)

Issue:
cargo +nightly install racer Error
I am trying to install *racer*, but I keep getting this error.
I tried setting *nightly* as default, didn't work either.

# Info
<pre>$ rustup show
<b>Default host: </b>x86_64-unknown-linux-gnu

<b>installed toolchains</b>
<b>--------------------</b>

stable-x86_64-unknown-linux-gnu (default)
nightly-x86_64-unknown-linux-gnu

<b>active toolchain</b>
<b>----------------</b>

stable-x86_64-unknown-linux-gnu (default)
rustc 1.37.0 (eae3437df 2019-08-13)
</pre>

<pre>$ rustup update
<b>info: </b>syncing channel updates for &apos;stable-x86_64-unknown-linux-gnu&apos;
<b>info: </b>syncing channel updates for &apos;nightly-x86_64-unknown-linux-gnu&apos;
<b>info: </b>checking for self-updates

   <b>stable-x86_64-unknown-linux-gnu unchanged</b> - rustc 1.37.0 (eae3437df 2019-08-13)
  <b>nightly-x86_64-unknown-linux-gnu unchanged</b> - rustc 1.39.0-nightly (618768492 2019-09-05)
</pre>

# Fail
<pre>$ cargo +nightly install racer
<font color="#55FF55"><b>    Updating</b></font> crates.io index
<font color="#55FF55"><b>  Installing</b></font> racer v2.1.25
<font color="#55FF55"><b>   Compiling</b></font> autocfg v0.1.6
<font color="#55FF55"><b>   Compiling</b></font> libc v0.2.62
<font color="#55FF55"><b>   Compiling</b></font> semver-parser v0.7.0
<font color="#55FF55"><b>   Compiling</b></font> arrayvec v0.4.11
<font color="#55FF55"><b>   Compiling</b></font> rand_core v0.4.2
<font color="#55FF55"><b>   Compiling</b></font> nodrop v0.1.13
<font color="#55FF55"><b>   Compiling</b></font> cfg-if v0.1.9
<font color="#55FF55"><b>   Compiling</b></font> proc-macro2 v0.4.30
<font color="#55FF55"><b>   Compiling</b></font> scopeguard v0.3.3
<font color="#55FF55"><b>   Compiling</b></font> memoffset v0.2.1
<font color="#55FF55"><b>   Compiling</b></font> lazy_static v1.4.0
<font color="#55FF55"><b>   Compiling</b></font> stable_deref_trait v1.1.1
<font color="#55FF55"><b>   Compiling</b></font> rustc-rayon-core v0.2.0
<font color="#55FF55"><b>   Compiling</b></font> log v0.4.8
<font color="#55FF55"><b>   Compiling</b></font> proc-macro2 v1.0.2
<font color="#55FF55"><b>   Compiling</b></font> byteorder v1.3.2
<font color="#55FF55"><b>   Compiling</b></font> unicode-xid v0.1.0
<font color="#55FF55"><b>   Compiling</b></font> smallvec v0.6.10
<font color="#55FF55"><b>   Compiling</b></font> syn v0.15.44
<font color="#55FF55"><b>   Compiling</b></font> rustc-rayon v0.2.0
<font color="#55FF55"><b>   Compiling</b></font> unicode-xid v0.2.0
<font color="#55FF55"><b>   Compiling</b></font> either v1.5.2
<font color="#55FF55"><b>   Compiling</b></font> syn v1.0.5
<font color="#55FF55"><b>   Compiling</b></font> indexmap v1.1.0
<font color="#55FF55"><b>   Compiling</b></font> rustc-ap-graphviz v546.0.0
<font color="#55FF55"><b>   Compiling</b></font> memchr v2.2.1
<font color="#55FF55"><b>   Compiling</b></font> bitflags v1.1.0
<font color="#55FF55"><b>   Compiling</b></font> serde v1.0.99
<font color="#55FF55"><b>   Compiling</b></font> ryu v1.0.0
<font color="#55FF55"><b>   Compiling</b></font> rustc-ap-rustc_target v546.0.0
<font color="#55FF55"><b>   Compiling</b></font> scoped-tls v1.0.0
<font color="#55FF55"><b>   Compiling</b></font> unicode-width v0.1.6
<font color="#55FF55"><b>   Compiling</b></font> quick-error v1.2.2
<font color="#55FF55"><b>   Compiling</b></font> termcolor v1.0.5
<font color="#55FF55"><b>   Compiling</b></font> annotate-snippets v0.6.1
<font color="#55FF55"><b>   Compiling</b></font> itoa v0.4.4
<font color="#55FF55"><b>   Compiling</b></font> rustc-ap-syntax v546.0.0
<font color="#55FF55"><b>   Compiling</b></font> regex-syntax v0.6.12
<font color="#55FF55"><b>   Compiling</b></font> vec_map v0.8.1
<font color="#55FF55"><b>   Compiling</b></font> strsim v0.8.0
<font color="#55FF55"><b>   Compiling</b></font> rustc-ap-rustc_lexer v546.0.0
<font color="#FF5555"><b>error[E0433]</b></font><b>: failed to resolve: could not find `property` in `unicode`</b>
   <font color="#5555FF"><b>--&gt; </b></font>/home/marx/.cargo/registry/src/github.com-1ecc6299db9ec823/rustc-ap-rustc_lexer-546.0.0/src/lib.rs:672:24
    <font color="#5555FF"><b>|</b></font>
<font color="#5555FF"><b>672</b></font> <font color="#5555FF"><b>| </b></font>        core::unicode::property::Pattern_White_Space(c)
    <font color="#5555FF"><b>| </b></font>                       <font color="#FF5555"><b>^^^^^^^^</b></font> <font color="#FF5555"><b>could not find `property` in `unicode`</b></font>

<font color="#FF5555"><b>error[E0599]</b></font><b>: no method named `is_xid_start` found for type `char` in the current scope</b>
   <font color="#5555FF"><b>--&gt; </b></font>/home/marx/.cargo/registry/src/github.com-1ecc6299db9ec823/rustc-ap-rustc_lexer-546.0.0/src/lib.rs:689:33
    <font color="#5555FF"><b>|</b></font>
<font color="#5555FF"><b>689</b></font> <font color="#5555FF"><b>| </b></font>            || (c &gt; &apos;\x7f&apos; &amp;&amp; c.is_xid_start())
    <font color="#5555FF"><b>| </b></font>                                <font color="#FF5555"><b>^^^^^^^^^^^^</b></font>

<font color="#FF5555"><b>error[E0599]</b></font><b>: no method named `is_xid_continue` found for type `char` in the current scope</b>
   <font color="#5555FF"><b>--&gt; </b></font>/home/marx/.cargo/registry/src/github.com-1ecc6299db9ec823/rustc-ap-rustc_lexer-546.0.0/src/lib.rs:708:33
    <font color="#5555FF"><b>|</b></font>
<font color="#5555FF"><b>708</b></font> <font color="#5555FF"><b>| </b></font>            || (c &gt; &apos;\x7f&apos; &amp;&amp; c.is_xid_continue())
    <font color="#5555FF"><b>| </b></font>                                <font color="#FF5555"><b>^^^^^^^^^^^^^^^</b></font>

<font color="#FF5555"><b>error</b></font><b>: aborting due to 3 previous errors</b>

<b>Some errors have detailed explanations: E0433, E0599.</b>
<b>For more information about an error, try `rustc --explain E0433`.</b>
<font color="#FF5555"><b>error</b></font><b>:</b> Could not compile `rustc-ap-rustc_lexer`.
<font color="#FFFF55"><b>warning</b></font><b>:</b> build failed, waiting for other jobs to finish...
<font color="#FF5555"><b>error</b></font><b>:</b> failed to compile `racer v2.1.25`, intermediate artifacts can be found at `/tmp/cargo-installsc6zOC`

Caused by:
  build failed
</pre>
Failed to build
Hey I ran the command, `cargo +nightly install racer` but it failed to build. Am I missing something, I'm still pretty new to rust.

I'm using `rustc 1.39.0-nightly (618768492 2019-09-05)`

```
error[E0433]: failed to resolve: could not find `property` in `unicode`
   --> /home/pepijn/.cargo/registry/src/github.com-1ecc6299db9ec823/rustc-ap-rustc_lexer-546.0.0/src/lib.rs:672:24
    |
672 |         core::unicode::property::Pattern_White_Space(c)
    |                        ^^^^^^^^ could not find `property` in `unicode`

   Compiling ansi_term v0.11.0
error[E0599]: no method named `is_xid_start` found for type `char` in the current scope
   --> /home/pepijn/.cargo/registry/src/github.com-1ecc6299db9ec823/rustc-ap-rustc_lexer-546.0.0/src/lib.rs:689:33
    |
689 |             || (c > '\x7f' && c.is_xid_start())
    |                                 ^^^^^^^^^^^^

error[E0599]: no method named `is_xid_continue` found for type `char` in the current scope
   --> /home/pepijn/.cargo/registry/src/github.com-1ecc6299db9ec823/rustc-ap-rustc_lexer-546.0.0/src/lib.rs:708:33
    |
708 |             || (c > '\x7f' && c.is_xid_continue())
    |                                 ^^^^^^^^^^^^^^^

error: aborting due to 3 previous errors

Some errors have detailed explanations: E0433, E0599.
For more information about an error, try `rustc --explain E0433`.
error: Could not compile `rustc-ap-rustc_lexer`.
warning: build failed, waiting for other jobs to finish...
error: failed to compile `racer v2.1.25`, intermediate artifacts can be found at `/tmp/cargo-installPy5axv`

Caused by:
  build failed
```


Discussion / hints:

Fix patch:
diff --git a/Cargo.lock b/Cargo.lock
index 669586f8..b89351d1 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -198,6 +198,15 @@ dependencies = [
  "rand 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
+[[package]]
+name = "kernel32-sys"
+version = "0.2.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+dependencies = [
+ "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
+ "winapi-build 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
+]
+
 [[package]]
 name = "lazy_static"
 version = "1.2.0"
@@ -322,7 +331,7 @@ dependencies = [
  "racer-cargo-metadata 0.1.1",
  "racer-testutils 0.1.0",
  "rls-span 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-syntax 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-syntax 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -504,21 +513,21 @@ dependencies = [
 
 [[package]]
 name = "rustc-ap-arena"
-version = "546.0.0"
+version = "581.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "rustc-ap-rustc_data_structures 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-rustc_data_structures 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "rustc-ap-graphviz"
-version = "546.0.0"
+version = "581.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "rustc-ap-rustc_data_structures"
-version = "546.0.0"
+version = "581.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "cfg-if 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -529,8 +538,8 @@ dependencies = [
  "lazy_static 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "parking_lot 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-graphviz 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-serialize 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-graphviz 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-serialize 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-hash 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-rayon 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-rayon-core 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -540,27 +549,31 @@ dependencies = [
 
 [[package]]
 name = "rustc-ap-rustc_errors"
-version = "546.0.0"
+version = "581.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "annotate-snippets 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "atty 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-rustc_data_structures 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-serialize 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-syntax_pos 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-rustc_data_structures 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-serialize 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-syntax_pos 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "term_size 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "termcolor 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "unicode-width 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "rustc-ap-rustc_lexer"
-version = "546.0.0"
+version = "581.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
+dependencies = [
+ "unicode-xid 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
+]
 
 [[package]]
 name = "rustc-ap-rustc_macros"
-version = "546.0.0"
+version = "581.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "itertools 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -572,19 +585,19 @@ dependencies = [
 
 [[package]]
 name = "rustc-ap-rustc_target"
-version = "546.0.0"
+version = "581.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "bitflags 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-rustc_data_structures 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-serialize 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-syntax_pos 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-rustc_data_structures 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-serialize 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-syntax_pos 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "rustc-ap-serialize"
-version = "546.0.0"
+version = "581.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "indexmap 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -593,33 +606,33 @@ dependencies = [
 
 [[package]]
 name = "rustc-ap-syntax"
-version = "546.0.0"
+version = "581.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "bitflags 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-rustc_data_structures 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-rustc_errors 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-rustc_lexer 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-rustc_macros 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-rustc_target 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-serialize 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-syntax_pos 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-rustc_data_structures 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-rustc_errors 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-rustc_lexer 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-rustc_macros 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-rustc_target 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-serialize 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-syntax_pos 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "scoped-tls 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.6.8 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "rustc-ap-syntax_pos"
-version = "546.0.0"
+version = "581.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "cfg-if 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-arena 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-rustc_data_structures 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-rustc_macros 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "rustc-ap-serialize 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-arena 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-rustc_data_structures 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-rustc_macros 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustc-ap-serialize 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "scoped-tls 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "unicode-width 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
@@ -769,6 +782,16 @@ dependencies = [
  "winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
+[[package]]
+name = "term_size"
+version = "0.3.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+dependencies = [
+ "kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.48 (registry+https://github.com/rust-lang/crates.io-index)",
+ "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
+]
+
 [[package]]
 name = "termcolor"
 version = "1.0.4"
@@ -818,6 +841,11 @@ name = "unicode-xid"
 version = "0.1.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
+[[package]]
+name = "unicode-xid"
+version = "0.2.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+
 [[package]]
 name = "unreachable"
 version = "1.0.0"
@@ -841,6 +869,11 @@ name = "void"
 version = "1.0.2"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
+[[package]]
+name = "winapi"
+version = "0.2.8"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+
 [[package]]
 name = "winapi"
 version = "0.3.6"
@@ -850,6 +883,11 @@ dependencies = [
  "winapi-x86_64-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
+[[package]]
+name = "winapi-build"
+version = "0.1.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+
 [[package]]
 name = "winapi-i686-pc-windows-gnu"
 version = "0.4.0"
@@ -903,6 +941,7 @@ dependencies = [
 "checksum itertools 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)" = "5b8467d9c1cebe26feb08c640139247fac215782d35371ade9a2136ed6085358"
 "checksum itoa 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)" = "1306f3464951f30e30d12373d31c79fbd52d236e5e896fd92f96ec7babbbe60b"
 "checksum jobserver 0.1.13 (registry+https://github.com/rust-lang/crates.io-index)" = "b3d51e24009d966c8285d524dbaf6d60926636b2a89caee9ce0bd612494ddc16"
+"checksum kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7507624b29483431c0ba2d82aece8ca6cdba9382bff4ddd0f7490560c056098d"
 "checksum lazy_static 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "a374c89b9db55895453a74c1e38861d9deec0b01b405a82516e9d5de4820dea1"
 "checksum lazycell 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "b294d6fa9ee409a054354afc4352b0b9ef7ca222c69b8812cbea9e7d2bf3783f"
 "checksum libc 0.2.48 (registry+https://github.com/rust-lang/crates.io-index)" = "e962c7641008ac010fa60a7dfdc1712449f29c44ef2d4702394aea943ee75047"
@@ -935,16 +974,16 @@ dependencies = [
 "checksum regex-syntax 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)" = "8c2f35eedad5295fdf00a63d7d4b238135723f92b434ec06774dad15c7ab0861"
 "checksum remove_dir_all 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)" = "3488ba1b9a2084d38645c4c08276a1752dcbf2c7130d74f1569681ad5d2799c5"
 "checksum rls-span 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)" = "f1cb4694410d8d2ce43ccff3682f1c782158a018d5a9a92185675677f7533eb3"
-"checksum rustc-ap-arena 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "4dc2e1e68b64268c543bfa6e63e3c0d9ea58074c71396f42f76931f35a9287f9"
-"checksum rustc-ap-graphviz 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "c108d647ce0dd46477b048eafff5a6273b5652e02d47424b0cd684147379c811"
-"checksum rustc-ap-rustc_data_structures 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "656771744e0783cb8e4481e3b8b1f975687610aaf18833b898018111a0e0e582"
-"checksum rustc-ap-rustc_errors 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "e37064f6624bc799bfaa2968b61ee6880926dea2a8bba69f18aef6c8e69c9604"
-"checksum rustc-ap-rustc_lexer 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ef5bc0a971823637ea23a857f0ef1467f44b1e05d71968821f83a0abe53e0fe3"
-"checksum rustc-ap-rustc_macros 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "b90037e3336fe8835f468db44d0848ae10d9cc8533ae89b55828883f905b7e80"
-"checksum rustc-ap-rustc_target 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "cadf9ca07315eab3a7a21f63872f9cc81e250fd6ede0419c24f8926ade73a45d"
-"checksum rustc-ap-serialize 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "61673783f2089e01033ffa82d1988f55175402071b31253a358292e1624d4602"
-"checksum rustc-ap-syntax 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "28f3dd1346d5b0269c07a4a78855e309a298ab569c9c1302d4d4f57f8eee4e84"
-"checksum rustc-ap-syntax_pos 546.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "45e67b526dbda3a0c7dab91c8947d43685e7697f52686a4949da3c179cd7c979"
+"checksum rustc-ap-arena 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "e4efec6ece174df54e4605c3c229b5a8885355f9f8988cabbc24aa99dbc27f27"
+"checksum rustc-ap-graphviz 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "b01d685fc49fb05676a8829c7a9fa1759c441f1430384c32c8b42462409535f3"
+"checksum rustc-ap-rustc_data_structures 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "2e43082631e0b3782c216d02d7d86a221b58834a1b3ba2b686aa84309bd65ed9"
+"checksum rustc-ap-rustc_errors 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "1ad386fc563e7e5ab47d78eaf2ee37d430e1e6c0ca67a23df70fdee9c4bdf673"
+"checksum rustc-ap-rustc_lexer 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "c3820240b53041ee8932c866aaf9c877e3a55af31a2f5c333077b853e9bed2ac"
+"checksum rustc-ap-rustc_macros 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "89b0931fe770efb7bc659e1900ef80d7bc8efeb4a36af94c5a89bea9e0230989"
+"checksum rustc-ap-rustc_target 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "26a3d9de9e308ba21add5f92bc2dfd014f3ea06932df7ba10ac23c83c0c9bc03"
+"checksum rustc-ap-serialize 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "1e9f98141be65d2cc0bc8eb11e89bda9d4cec9ddf69dd46120c8f3840f9b5adc"
+"checksum rustc-ap-syntax 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "5643c677373d8fa1f19c93ce7b42f5628818964d4d3d7dc6ac191b2b6170e91b"
+"checksum rustc-ap-syntax_pos 581.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "1508b6dc46181580787b30876bc8cc1c76ca5851aec05d08e0065cd16c635736"
 "checksum rustc-hash 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)" = "7540fc8b0c49f096ee9c961cda096467dce8084bec6bdca2fc83895fd9b28cb8"
 "checksum rustc-rayon 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "0d2e07e19601f21c59aad953c2632172ba70cb27e685771514ea66e4062b3363"
 "checksum rustc-rayon-core 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "79d38ca7cbc22fa59f09d8534ea4b27f67b0facf0cbe274433aceea227a02543"
@@ -963,6 +1002,7 @@ dependencies = [
 "checksum syn 0.15.26 (registry+https://github.com/rust-lang/crates.io-index)" = "f92e629aa1d9c827b2bb8297046c1ccffc57c99b947a680d3ccff1f136a3bee9"
 "checksum synstructure 0.10.2 (registry+https://github.com/rust-lang/crates.io-index)" = "02353edf96d6e4dc81aea2d8490a7e9db177bf8acb0e951c24940bf866cb313f"
 "checksum tempfile 3.0.6 (registry+https://github.com/rust-lang/crates.io-index)" = "37daa55a7240c4931c84559f03b3cad7d19535840d1c4a0cc4e9b2fb0dcf70ff"
+"checksum term_size 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "9e5b9a66db815dcfd2da92db471106457082577c3c278d4138ab3e3b4e189327"
 "checksum termcolor 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)" = "4096add70612622289f2fdcdbd5086dc81c1e2675e6ae58d6c4f62a16c6d7f2f"
 "checksum termion 1.5.1 (registry+https://github.com/rust-lang/crates.io-index)" = "689a3bdfaab439fd92bc87df5c4c78417d3cbe537487274e9b0b2dce76e92096"
 "checksum textwrap 0.10.0 (registry+https://github.com/rust-lang/crates.io-index)" = "307686869c93e71f94da64286f9a9524c0f308a9e1c87a583de8e9c9039ad3f6"
@@ -970,11 +1010,14 @@ dependencies = [
 "checksum ucd-util 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "535c204ee4d8434478593480b8f86ab45ec9aae0e83c568ca81abf0fd0e88f86"
 "checksum unicode-width 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "882386231c45df4700b275c7ff55b6f3698780a650026380e72dabe76fa46526"
 "checksum unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "fc72304796d0818e357ead4e000d19c9c174ab23dc11093ac919054d20a6a7fc"
+"checksum unicode-xid 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "826e7639553986605ec5979c7dd957c7895e93eabed50ab2ffa7f6128a75097c"
 "checksum unreachable 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "382810877fe448991dfc7f0dd6e3ae5d58088fd0ea5e35189655f84e6814fa56"
 "checksum utf8-ranges 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)" = "796f7e48bef87609f7ade7e06495a87d5cd06c7866e6a5cbfceffc558a243737"
 "checksum vec_map 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)" = "05c78687fb1a80548ae3250346c3db86a80a7cdd77bda190189f2d0a0987c81a"
 "checksum void 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)" = "6a02e4885ed3bc0f2de90ea6dd45ebcbb66dacffe03547fadbb0eeae2770887d"
+"checksum winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)" = "167dc9d6949a9b857f3451275e911c3f44255842c1f7a76f33c55103a909087a"
 "checksum winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)" = "92c1eb33641e276cfa214a0522acad57be5c56b10cb348b3c5117db75f3ac4b0"
+"checksum winapi-build 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "2d315eee3b34aca4797b2da6b13ed88266e6d612562a0c46390af8299fc699bc"
 "checksum winapi-i686-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6"
 "checksum winapi-util 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7168bab6e1daee33b4557efd0e95d5ca70a03706d39fa5f3fe7a236f584b03c9"
 "checksum winapi-x86_64-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f"
diff --git a/Cargo.toml b/Cargo.toml
index 1c8c9c5d..0eb08ab7 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -24,7 +24,7 @@ debug = false # because of #1005
 [dependencies]
 bitflags = "1.0"
 log = "0.4"
-rustc-ap-syntax = "546.0.0"
+rustc-ap-syntax = "581.0.0"
 env_logger = "0.6"
 clap = "2.32"
 lazy_static = "1.2"
diff --git a/src/racer/ast.rs b/src/racer/ast.rs
index 26e9a0f8..e37dcc42 100644
--- a/src/racer/ast.rs
+++ b/src/racer/ast.rs
@@ -315,7 +315,7 @@ fn destructure_pattern_to_ty(
             for child in children {
                 if point_is_in_span(point, &child.span) {
                     return typeinf::get_struct_field_type(
-                        &child.node.ident.name.as_str(),
+                        &child.ident.name.as_str(),
                         &m,
                         session,
                     )
@@ -327,7 +327,7 @@ fn destructure_pattern_to_ty(
                         }
                     })
                     .and_then(|ty| {
-                        destructure_pattern_to_ty(&child.node.pat, point, &ty, scope, session)
+                        destructure_pattern_to_ty(&child.pat, point, &ty, scope, session)
                     });
                 }
             }
@@ -745,7 +745,7 @@ impl<'c, 's, 'ast> visit::Visitor<'ast> for ExprTypeVisitor<'c, 's> {
                 }
             }
             ExprKind::Mac(ref m) => {
-                if let Some(name) = m.node.path.segments.last().map(|seg| seg.ident) {
+                if let Some(name) = m.path.segments.last().map(|seg| seg.ident) {
                     // use some ad-hoc rules
                     if name.as_str() == "vec" {
                         let path = RacerPath::from_iter(
@@ -868,10 +868,6 @@ impl<'ast> visit::Visitor<'ast> for StructVisitor {
     fn visit_variant_data(
         &mut self,
         struct_definition: &ast::VariantData,
-        _: ast::Ident,
-        _: &ast::Generics,
-        _: ast::NodeId,
-        _: Span,
     ) {
         for field in struct_definition.fields() {
             let ty = Ty::from_ast(&field.ty, &self.scope);
@@ -894,7 +890,7 @@ pub struct TypeVisitor<'s> {
 
 impl<'ast, 's> visit::Visitor<'ast> for TypeVisitor<'s> {
     fn visit_item(&mut self, item: &ast::Item) {
-        if let ItemKind::Ty(ref ty, _) = item.node {
+        if let ItemKind::TyAlias(ref ty, _) = item.node {
             self.name = Some(item.ident.name.to_string());
             self.type_ = Ty::from_ast(&ty, self.scope);
             debug!("typevisitor type is {:?}", self.type_);
@@ -1001,7 +997,7 @@ impl<'ast> visit::Visitor<'ast> for EnumVisitor {
             for variant in &enum_definition.variants {
                 let source_map::BytePos(point) = variant.span.lo();
                 self.values
-                    .push((variant.node.ident.to_string(), point.into()));
+                    .push((variant.ident.to_string(), point.into()));
             }
         }
     }
diff --git a/src/racer/ast_types.rs b/src/racer/ast_types.rs
index 6d865c8e..36679122 100644
--- a/src/racer/ast_types.rs
+++ b/src/racer/ast_types.rs
@@ -271,6 +271,7 @@ pub enum Pat {
     Slice,
     Mac,
     Rest,
+    Or,
 }
 
 impl Pat {
@@ -304,7 +305,7 @@ impl Pat {
                 let path = Path::from_ast(path, scope);
                 let fields = fields
                     .iter()
-                    .map(|fld| FieldPat::from_ast(&fld.node, scope))
+                    .map(|fld| FieldPat::from_ast(&fld, scope))
                     .collect();
                 Pat::Struct(path, fields)
             }
@@ -333,6 +334,7 @@ impl Pat {
             PatKind::Paren(pat) => Pat::from_ast(&pat.node, scope),
             PatKind::Mac(_) => Pat::Mac,
             PatKind::Rest => Pat::Rest,
+            PatKind::Or(_) => Pat::Or,
         }
     }
 }


Test patch: