mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-28 12:54:58 +00:00
Give defaultLibrary semantic token modifier to items from standard library
This commit is contained in:
parent
161a5e8724
commit
2b3baa8503
11 changed files with 167 additions and 49 deletions
|
@ -734,6 +734,23 @@ fn test_extern_crate() {
|
|||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_default_library() {
|
||||
check_highlighting(
|
||||
r#"
|
||||
//- minicore: option, iterators
|
||||
use core::iter;
|
||||
|
||||
fn main() {
|
||||
let foo = Some(92);
|
||||
let nums = iter::repeat(foo.unwrap());
|
||||
}
|
||||
"#,
|
||||
expect_file!["./test_data/highlight_default_library.html"],
|
||||
false,
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_associated_function() {
|
||||
check_highlighting(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue