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

Codelens to get the references on fields is missing #350

Closed
awlok-dev opened this issue Aug 7, 2023 · 6 comments
Closed

Codelens to get the references on fields is missing #350

awlok-dev opened this issue Aug 7, 2023 · 6 comments
Labels
area-project Project load, Solution Explorer area-unity Unity support

Comments

@awlok-dev
Copy link

Type: Bug

  • Reference of fields are gone, there are only references for methods and classes
  • Constant readonly modifier advices for some private fields
    alt text
    alt text

C# and C# Dev Kit extension is updated
Visual Studio Editor package is updated
.NET 7 is installed

Extension version: 0.9.0
VS Code version: Code 1.81.0 (6445d93c81ebe42c4cbd7a60712e0b17d9463e97, 2023-08-02T12:37:13.485Z)
OS version: Windows_NT x64 10.0.19045
Modes:

System Info
Item Value
CPUs AMD Ryzen 5 1600 Six-Core Processor (12 x 3600)
GPU Status 2d_canvas: enabled
canvas_oop_rasterization: disabled_off
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
video_decode: enabled
video_encode: enabled
vulkan: disabled_off
webgl: enabled
webgl2: enabled
webgpu: enabled
Load (avg) undefined
Memory (System) 15.95GB (7.63GB free)
Process Argv --crash-reporter-id db49d959-a85e-4b8f-96a2-6f8616d89334
Screen Reader no
VM 0%
A/B Experiments
vsliv368:30146709
vsreu685:30147344
python383cf:30185419
vspor879:30202332
vspor708:30202333
vspor363:30204092
vslsvsres303:30308271
vserr242:30382549
pythontb:30283811
vsjup518:30340749
pythonptprofiler:30281270
vshan820:30294714
vstes263:30335439
vscoreces:30445986
vscod805cf:30301675
binariesv615:30325510
bridge0708:30335490
bridge0723:30353136
vsaa593cf:30376535
pythonvs932:30410667
py29gd2263:30792226
vsclangdc:30486549
c4g48928:30535728
dsvsc012cf:30540253
pynewext54:30695312
azure-dev_surveyone:30548225
vscccc:30803845
3biah626:30602489
f6dab269:30613381
a9j8j154:30646983
showlangstatbar:30737416
vsctsb:30748421
03d35959:30757346
pythonfmttext:30731395
pythoncmvfstrcf:30756944
fixshowwlkth:30771522
showindicator:30805244
pythongtdpath:30769146
i26e3531:30792625
gsofa:30804715
pythonnosmt12:30797651
pythonidxptcf:30805731
pythonnoceb:30805159
e537b577:30795824
dsvsc013:30795093
dsvsc014:30804076

@microsoft-issue-labeler microsoft-issue-labeler bot added the area-project Project load, Solution Explorer label Aug 7, 2023
@jbevain jbevain changed the title No reference of fields and some weird readonly advices Codelens to get the references on fields is missing Aug 7, 2023
@jbevain
Copy link
Member

jbevain commented Aug 7, 2023

The suggestion to make the field readonly makes sense if you're never writing to the field. If you don't like that suggestion, you can hide it with an .editorconfig file:

dotnet_style_readonly_field = false:none

@arunchndr
Copy link
Member

The C# release today will replace the blue squiggly lines to match the VS suggestion info with the triple dots - https://github.com/dotnet/vscode-csharp/pull/6074/files

@Skullester
Copy link

The C# release today will replace the blue Волнистые lines to match the VS suggestion info with the triple dots - https://github.com/dotnet/vscode-csharp/pull/6074/files
Will the release fix lack of references of fields?

@kvenkatrajan
Copy link

@Goshlok-git is this a unity project?

@arunchndr
Copy link
Member

References on fields is a special feature in O# that does not exist today in the Roslyn LSP or VS. We are looking to fill that feature gap once we work through our top issues list at dotnet/vscode-csharp#5736.

Moving this to vscode-csharp to track.

@awlok-dev
Copy link
Author

@Goshlok-git is this a unity project?

Yes, it's a unity project.

@kvenkatrajan kvenkatrajan added the area-unity Unity support label Aug 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-project Project load, Solution Explorer area-unity Unity support
Projects
None yet
Development

No branches or pull requests

5 participants