Skip to content
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

Bracket pair colorization mistakenly colors angle brackets in syntax #131176

Closed
Spanfile opened this issue Aug 19, 2021 · 5 comments
Closed

Bracket pair colorization mistakenly colors angle brackets in syntax #131176

Spanfile opened this issue Aug 19, 2021 · 5 comments

Comments

@Spanfile
Copy link

Issue Type: Bug

Bracket pair colorization mistakenly pairs two unrelated bitshift operators together. It also colors things like comparisons, return values and "thick" arrows.

image
image
image
image

VS Code version: Code - Insiders 1.60.0-insider (c089133, 2021-08-19T05:15:56.182Z)
OS version: Linux x64 5.13.12-xanmod1-span
Restricted Mode: No

System Info
Item Value
CPUs Intel(R) Core(TM) i7-9700K CPU @ 3.60GHz (8 x 3600)
GPU Status 2d_canvas: enabled
gpu_compositing: enabled
multiple_raster_threads: enabled_on
oop_rasterization: disabled_off
opengl: enabled_on
rasterization: disabled_software
skia_renderer: enabled_on
video_decode: disabled_software
vulkan: disabled_off
webgl: enabled
webgl2: enabled
Load (avg) 0, 0, 1
Memory (System) 31.29GB (3.54GB free)
Process Argv --unity-launch --crash-reporter-id bd9b53b6-bf9d-4112-a5f5-080f8f241743
Screen Reader no
VM 0%
DESKTOP_SESSION ubuntu
XDG_CURRENT_DESKTOP Unity
XDG_SESSION_DESKTOP ubuntu
XDG_SESSION_TYPE x11
Extensions (15)
Extension Author (truncated) Version
toml be5 0.5.1
better-toml bun 0.3.2
vscode-lua-format Koi 1.3.8
rust-analyzer mat 0.4.0-dev
vscode-docker ms- 1.16.0
python ms- 2021.8.1105858891
vscode-pylance ms- 2021.8.1
jupyter ms- 2021.8.2028630014
LiveServer rit 5.6.1
crates ser 0.5.9
vscode-zipexplorer sle 0.3.1
lua sum 2.3.7
vscode-lldb vad 1.6.5
markdown-all-in-one yzh 3.4.0
vscode-proto3 zxh 0.5.4
@vscodebot
Copy link

vscodebot bot commented Aug 19, 2021

(Experimental duplicate detection)
Thanks for submitting this issue. Please also check if it is already covered by an existing one, like:

@IllusionMH
Copy link
Contributor

/assign @hediet

@hediet
Copy link
Member

hediet commented Aug 19, 2021

That is because the rust language defined < ... > as bracket pair.

@alexdima do you have ideas how to fix this?

  1. Have a global language override for bracket pair colorization
  2. Ask the rust extension to remove <...>
  3. Remove < ... > when doing bracket pair colorization for every language (as this is also problematic for jsx)
  4. ?

@IllusionMH
Copy link
Contributor

Is it possible to add language specific overrides for brackets pairs in config?

"[typescriptreact]": {
    "editor.bracketPairColorization.pairs": [
        ["{", "}"],
        ["[", "]"],
        ["(", ")"]
    ]
}

Or other way to specify subset of pairs provided by language. Or expend it if implementation supports expanding list of pairs and don't rely on language implementation.

@hediet
Copy link
Member

hediet commented Aug 23, 2021

This issue would be fixed by either #131412 (user configurable bracket pairs, including colorized bracket pairs) or #131194 (language configurable colorized bracket pairs).

@hediet hediet closed this as completed Aug 23, 2021
@github-actions github-actions bot locked and limited conversation to collaborators Oct 7, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants