You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Everything is working as intended, when using union as a struct, but as soon as you start to use it as variable name, or call a union() function on a set, the highlighting for the rest of the code, starts to go crazy.
Examples:
// This is fine#[repr(C)]unionMyUnion{f1:u32,f2:f32,}
// If you create a variable called `union`, things starts to break down:let union:Vec<i32> = vec![1,2,3];assert_eq!(union,(1..=3).collect::<Vec<i32>>());
use std::collections::HashSet;letmut a:HashSet<i32> = (0..4).collect();letmut b:HashSet<i32> = (4..8).collect();// But when you combine `union()` function with a print macro,// the results are more than weird ...for x in a.union(&b){print!("{} ", x);}// ... and the rest of the code is highlighted like one big string literal.
Here's a screenshot to better illustrate the problem:
Color theme is Cobalt
Sublime Text Version
Sublime Text 3.2.1 (Build 3207)
Rust Enhanced Version
2.20.00
Operating system
OS: Windows 10 Pro
Version: 10.0.18362 build 18362
The text was updated successfully, but these errors were encountered:
Everything is working as intended, when using
union
as a struct, but as soon as you start to use it as variable name, or call aunion()
function on a set, the highlighting for the rest of the code, starts to go crazy.Examples:
Here's a screenshot to better illustrate the problem:
Color theme is Cobalt
Sublime Text Version
Sublime Text 3.2.1 (Build 3207)
Rust Enhanced Version
2.20.00
Operating system
OS: Windows 10 Pro
Version: 10.0.18362 build 18362
The text was updated successfully, but these errors were encountered: