rust-lang / rust-analyzer

A Rust compiler front-end for IDEs
https://rust-analyzer.github.io/
Apache License 2.0
14.32k stars 1.61k forks source link

Inlay type hints didn't show for chained expressions #18471

Open xky0007 opened 2 weeks ago

xky0007 commented 2 weeks ago

rust-analyzer version: rust-analyzer version: 0.3.2162-standalone (3b3a87fe9 2024-10-27)

rustc version: rustc 1.82.0 (f6e511eec 2024-10-15)

editor or extension: Vs-Code

relevant settings: (eg. client settings, or environment variables like CARGO, RUSTC, RUSTUP_HOME or CARGO_HOME)

repository link (if public, optional): (eg. rust-analyzer)

code snippet to reproduce:

use reqwest::header::{HeaderMap, HeaderValue};
use std::error::Error;

#[tokio::main]
async fn main() -> Result<(), Box<dyn Error>> {
    let client = reqwest::Client::new();

    // Create custom headers
    let mut headers = HeaderMap::new();
    headers.insert("Authorization", HeaderValue::from_static("Bearer  "));

    // Send HTTP GET request
    let response = client
        .post("https://n.cg.163.com/api/v2/sign-today")
        .headers(headers)  
        .send()
        .await?;

    println!("Status: {}", response.status());
    println!("Content: {}", response.text().await?);
    Ok(())
}

Type hints didn't show after first line of chained expressions. Image