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

Merge 'dotnet/main' into PrimaryConstructors #67111

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
513 commits
Select commit Hold shift + click to select a range
16d0d6f
Simplify
CyrusNajmabadi Feb 19, 2023
8d2eec8
Simplify
CyrusNajmabadi Feb 19, 2023
b318f37
Use pattern
CyrusNajmabadi Feb 19, 2023
de04a84
Use pattern
CyrusNajmabadi Feb 19, 2023
7ef683f
Use pattern
CyrusNajmabadi Feb 19, 2023
791506a
Use pattern
CyrusNajmabadi Feb 19, 2023
6a25f01
Use pattern
CyrusNajmabadi Feb 19, 2023
c9a55d8
Use pattern
CyrusNajmabadi Feb 19, 2023
191e076
Use pattern
CyrusNajmabadi Feb 19, 2023
07d0a62
Use pattern
CyrusNajmabadi Feb 19, 2023
28b0db6
Use pattern
CyrusNajmabadi Feb 19, 2023
d48700b
Use pattern
CyrusNajmabadi Feb 19, 2023
7f89c1f
Use pattern
CyrusNajmabadi Feb 19, 2023
89660e8
Use pattern
CyrusNajmabadi Feb 19, 2023
f404a6a
Use pattern
CyrusNajmabadi Feb 19, 2023
f470752
Use pattern
CyrusNajmabadi Feb 19, 2023
cfb1045
Use pattern
CyrusNajmabadi Feb 19, 2023
8440600
Use pattern
CyrusNajmabadi Feb 19, 2023
9a12f19
Use pattern
CyrusNajmabadi Feb 19, 2023
0da398e
Use pattern
CyrusNajmabadi Feb 19, 2023
69e8624
Use pattern
CyrusNajmabadi Feb 19, 2023
99aa12b
Use pattern
CyrusNajmabadi Feb 19, 2023
a684c35
Use pattern
CyrusNajmabadi Feb 19, 2023
13b326d
Use pattern
CyrusNajmabadi Feb 19, 2023
00074a9
Use pattern
CyrusNajmabadi Feb 19, 2023
58dfba8
Use pattern
CyrusNajmabadi Feb 19, 2023
f3d31dd
Use pattern
CyrusNajmabadi Feb 19, 2023
c63c5c0
Simplify
CyrusNajmabadi Feb 19, 2023
96295fb
Simplify
CyrusNajmabadi Feb 19, 2023
b3ebbdc
Simplify
CyrusNajmabadi Feb 19, 2023
3b93ca1
Update options
CyrusNajmabadi Feb 19, 2023
c660372
Fix test
CyrusNajmabadi Feb 19, 2023
29aa331
Update options
CyrusNajmabadi Feb 19, 2023
766b782
Fix test
CyrusNajmabadi Feb 19, 2023
6589aef
Fix test
CyrusNajmabadi Feb 19, 2023
e5f85bc
Lint
CyrusNajmabadi Feb 20, 2023
1b3a210
Fix
CyrusNajmabadi Feb 20, 2023
e67f84a
Update src/Analyzers/CSharp/CodeFixes/ConvertToRecord/ConvertToRecord…
CyrusNajmabadi Feb 20, 2023
9a26fea
Simplify
CyrusNajmabadi Feb 20, 2023
af5d9c1
Better pattern usage
CyrusNajmabadi Feb 20, 2023
75e07e8
Fix
CyrusNajmabadi Feb 20, 2023
7235caf
Simplify more
CyrusNajmabadi Feb 20, 2023
067b2c4
Simplify more
CyrusNajmabadi Feb 20, 2023
b08a9dc
Simplify more
CyrusNajmabadi Feb 20, 2023
977ddc7
Simplify more
CyrusNajmabadi Feb 20, 2023
a9fdc85
Simplify more
CyrusNajmabadi Feb 20, 2023
4190056
Merge pull request #66956 from CyrusNajmabadi/usePatterns
CyrusNajmabadi Feb 20, 2023
10ffefe
Revert "Provide access to F# integration tests"
psfinaki Feb 20, 2023
2c8a1da
Merge remote-tracking branch 'upstream/main' into psfinaki/fsharp-int…
psfinaki Feb 20, 2023
dd398d6
Update Microsoft.CodeAnalysis.ExternalAccess.FSharp.csproj
psfinaki Feb 20, 2023
2f916e6
Fix
CyrusNajmabadi Feb 20, 2023
0156fe3
Merge remote-tracking branch 'upstream/main' into makeStructMemberRea…
CyrusNajmabadi Feb 20, 2023
6a894d5
Fix
CyrusNajmabadi Feb 21, 2023
f59969d
revert
CyrusNajmabadi Feb 21, 2023
006abc2
CodeStyleOption2 refactoring (#66946)
tmat Feb 21, 2023
feba39e
Improve parser error recovery in malformed switch statements
CyrusNajmabadi Feb 21, 2023
658ed76
Revert
CyrusNajmabadi Feb 21, 2023
9a47831
Merge pull request #66945 from jasonmalinowski/delete-unused-service-…
jasonmalinowski Feb 21, 2023
7010ea7
Update additional test
CyrusNajmabadi Feb 21, 2023
272d2a1
Record buddies for roles/extensions feature (#66980)
jcouv Feb 21, 2023
0468203
Do not treat context as expression context in the middle of `..` token
DoctorKrolic Feb 21, 2023
9ffa0b0
Merge pull request #66947 from jasonmalinowski/fix-brokered-service-i…
jasonmalinowski Feb 21, 2023
6ca4295
Fix case with whitespace between the token and current position
DoctorKrolic Feb 21, 2023
e21918f
Remove opt suffix
DoctorKrolic Feb 21, 2023
08318a2
Add whitespace test
DoctorKrolic Feb 21, 2023
4f464df
Merge pull request #66979 from CyrusNajmabadi/switchRecovery
CyrusNajmabadi Feb 21, 2023
1cca534
Add comment
DoctorKrolic Feb 21, 2023
c802c60
Merge remote-tracking branch 'upstream/main' into makeStructMemberRea…
CyrusNajmabadi Feb 21, 2023
e728eff
Introduce Parameter - Fix crash (#66402)
akhera99 Feb 21, 2023
6b59cde
Add some tests for implement implicitly/explicitly
CyrusNajmabadi Feb 21, 2023
7446a4f
Merge remote-tracking branch 'upstream/main' into makeStructMemberRea…
CyrusNajmabadi Feb 21, 2023
d703fc8
Add tests
CyrusNajmabadi Feb 21, 2023
b598516
Add tests
CyrusNajmabadi Feb 21, 2023
1f66319
In progress
CyrusNajmabadi Feb 21, 2023
f35ace6
Compiling
CyrusNajmabadi Feb 21, 2023
94158d6
in progress
CyrusNajmabadi Feb 21, 2023
c228f79
in progress
CyrusNajmabadi Feb 21, 2023
728ad8f
Fix
CyrusNajmabadi Feb 21, 2023
8d8ff93
Fix
CyrusNajmabadi Feb 21, 2023
bbf3b33
Fix tests
CyrusNajmabadi Feb 22, 2023
6186339
Add wokritem
CyrusNajmabadi Feb 22, 2023
d53007d
Update test
DoctorKrolic Feb 22, 2023
faddecd
Merge branch 'main' into psfinaki/fsharp-integration-tests
psfinaki Feb 22, 2023
4e3a326
Merge pull request #66926 from psfinaki/psfinaki/fsharp-integration-t…
psfinaki Feb 22, 2023
8d4c1d5
Proper fix
DoctorKrolic Feb 22, 2023
be9f254
Squash conditions
DoctorKrolic Feb 22, 2023
0a7aec0
Merge pull request #66929 from CyrusNajmabadi/expandValueTuple
CyrusNajmabadi Feb 22, 2023
64a259e
Properly use 'ValueTuple' instead of native tuples in cref syntax.
CyrusNajmabadi Feb 22, 2023
d08f7de
Fix 'tuple can be deconstructed' issue with top level statements
CyrusNajmabadi Feb 22, 2023
3786f21
Simplify
CyrusNajmabadi Feb 22, 2023
7347efa
Fix flag value in option fallback reader (#66967)
tmat Feb 22, 2023
4b86d6e
Delete folders
CyrusNajmabadi Feb 22, 2023
88ec05e
Delete folders
CyrusNajmabadi Feb 22, 2023
0deb0f4
Run analyzer on IDE
CyrusNajmabadi Feb 22, 2023
fb0c061
Remove CheckServerState
ryanbrandenburg Feb 22, 2023
2079656
Merge remote-tracking branch 'upstream/main' into sigHelpInProgress
CyrusNajmabadi Feb 22, 2023
ac7d791
NRT
CyrusNajmabadi Feb 22, 2023
83fcba0
NRT
CyrusNajmabadi Feb 22, 2023
8273c98
Allow missing CommandLineArgsForDesignTimeEvaluation msbuild property…
tmat Jan 19, 2023
8e6f16f
Skip test
ryanbrandenburg Feb 22, 2023
b8e1499
Move to the regular queue instead of the scouting queue
dibarbet Feb 22, 2023
76f7525
Fix simplification in nameof expressions
CyrusNajmabadi Feb 22, 2023
9f121b4
Merge pull request #66083 from ryanbrandenburg/CLaSPReadme
ryanbrandenburg Feb 22, 2023
25d2624
Merge pull request #67000 from tmat/AllowMissingCommandLineArgsForDes…
arunchndr Feb 22, 2023
8c81621
Improve the spans that 'add parameter check' is supported in
CyrusNajmabadi Feb 22, 2023
13e745f
Simplify
CyrusNajmabadi Feb 22, 2023
7d91396
Restore
CyrusNajmabadi Feb 22, 2023
4f03aa6
Merge pull request #67001 from dotnet/dibarbet-patch-1
arunchndr Feb 22, 2023
1f40608
Fix test suite
CyrusNajmabadi Feb 22, 2023
81b6f5b
Merge remote-tracking branch 'upstream/main' into makeStructMemberRea…
CyrusNajmabadi Feb 22, 2023
b9d534e
Merge remote-tracking branch 'upstream/main' into makeMemberReadOnly2
CyrusNajmabadi Feb 22, 2023
dc50b80
Merge remote-tracking branch 'upstream/main' into deconstructTopLevel
CyrusNajmabadi Feb 22, 2023
43a0035
Merge remote-tracking branch 'upstream/main' into nameofSimplification
CyrusNajmabadi Feb 22, 2023
08db879
Merge remote-tracking branch 'upstream/main' into addParameterSpan
CyrusNajmabadi Feb 22, 2023
6374e72
Merge remote-tracking branch 'upstream/main' into sigHelpInProgress
CyrusNajmabadi Feb 22, 2023
2aaa7b3
Merge pull request #66985 from CyrusNajmabadi/interfaceTests
CyrusNajmabadi Feb 22, 2023
a994eb4
Fix crash in 'replae property with methods'
CyrusNajmabadi Feb 23, 2023
5e1c16f
Merge branch 'main' of github.com:dotnet/roslyn into OnInitialized
ryanbrandenburg Feb 23, 2023
e639228
Respect user specified new-line character in split-string
CyrusNajmabadi Feb 23, 2023
81a5ee9
add workitems
CyrusNajmabadi Feb 23, 2023
f2a7fc3
Add missing DataContract attributes
jasonmalinowski Feb 23, 2023
168de19
Fix tests
DoctorKrolic Feb 23, 2023
a6bccda
Merge pull request #66954 from CyrusNajmabadi/makeStructMemberReadOnly
CyrusNajmabadi Feb 23, 2023
81db030
Merge branch 'main' of github.com:dotnet/roslyn into OnInitialized
ryanbrandenburg Feb 23, 2023
bedd7a3
Remove callback functionality from symbol search
CyrusNajmabadi Feb 23, 2023
74e281c
Merge remote-tracking branch 'upstream/main' into sigHelpInProgress
CyrusNajmabadi Feb 23, 2023
942502b
Merge remote-tracking branch 'upstream/main' into makeMemberReadOnly2
CyrusNajmabadi Feb 23, 2023
f5d63f2
Merge remote-tracking branch 'upstream/main' into deconstructTopLevel
CyrusNajmabadi Feb 23, 2023
8806ba5
Merge remote-tracking branch 'upstream/main' into nameofSimplification
CyrusNajmabadi Feb 23, 2023
d1fc4a7
Merge remote-tracking branch 'upstream/main' into addParameterSpan
CyrusNajmabadi Feb 23, 2023
1c50368
Merge remote-tracking branch 'upstream/main' into replacePropCrash
CyrusNajmabadi Feb 23, 2023
ef9c5b3
Merge pull request #66998 from ryanbrandenburg/OnInitialized
ryanbrandenburg Feb 23, 2023
bf31a76
Inline log
CyrusNajmabadi Feb 23, 2023
ba098bf
Simplify
CyrusNajmabadi Feb 23, 2023
fbe2b13
Ordering matters
CyrusNajmabadi Feb 23, 2023
6c42286
Merge remote-tracking branch 'upstream/main' into splitStringNewLine
CyrusNajmabadi Feb 23, 2023
8a377b0
Fix SymbolDisplay to use 'Operator' kind when producing the display f…
CyrusNajmabadi Feb 23, 2023
4c5d7ad
remove
CyrusNajmabadi Feb 23, 2023
cdbb31f
Merge remote-tracking branch 'upstream/main' into crefTuples
CyrusNajmabadi Feb 23, 2023
b172185
Merge pull request #66997 from CyrusNajmabadi/deconstructTopLevel
CyrusNajmabadi Feb 23, 2023
3a37d24
Add nullability info field into discard expression (#66309)
TomatorCZ Feb 23, 2023
727ebee
Pass cancellation token along
CyrusNajmabadi Feb 23, 2023
c5989cd
Fix
CyrusNajmabadi Feb 23, 2023
104f0dc
Merge pull request #66996 from CyrusNajmabadi/crefTuples
CyrusNajmabadi Feb 23, 2023
214bde6
Remove the PreviewWorkspace SolutionCrawler functionality
CyrusNajmabadi Feb 23, 2023
04da588
Remove unnecessary test
CyrusNajmabadi Feb 23, 2023
a459086
Make IWorkspaceProject implement IDisposable instead
jasonmalinowski Feb 23, 2023
92e5513
Merge pull request #67024 from CyrusNajmabadi/symbolSearchCallback
CyrusNajmabadi Feb 23, 2023
8b18ec4
Merge pull request #67009 from CyrusNajmabadi/splitStringNewLine
CyrusNajmabadi Feb 23, 2023
78e476a
Merge pull request #67008 from CyrusNajmabadi/replacePropCrash
CyrusNajmabadi Feb 23, 2023
271ccd7
Merge pull request #67006 from dotnet/merges/release/dev17.5-to-relea…
dotnet-bot Feb 24, 2023
af582bc
Update test to be pull based.
CyrusNajmabadi Feb 24, 2023
0c8dd2d
Fixup test to be pull not push
CyrusNajmabadi Feb 24, 2023
2d9056a
Disable diagnostics in the preview window
CyrusNajmabadi Feb 24, 2023
3e57878
Fix
CyrusNajmabadi Feb 24, 2023
4e92de3
Merge pull request #67033 from dotnet/merges/release/dev17.5-vs-deps-…
dotnet-bot Feb 24, 2023
a21b435
Merge pull request #67029 from jasonmalinowski/fix-brokered-service
jasonmalinowski Feb 24, 2023
87e6574
Merge pull request #67034 from dotnet/merges/release/dev17.6-to-main
dotnet-bot Feb 24, 2023
e99d9ee
Clean and rename FeatureOnOffOptions (#66881)
Cosifne Feb 24, 2023
dd8fb67
Merge pull request #67027 from CyrusNajmabadi/previewCrawler
mavasani Feb 24, 2023
b80df1b
Merge pull request #67030 from CyrusNajmabadi/disablePreviewDiagnostics
mavasani Feb 24, 2023
bb844c9
Revert "Disable diagnostics in the preview window"
sharwell Feb 24, 2023
78e26bb
Merge pull request #67002 from CyrusNajmabadi/nameofSimplification
CyrusNajmabadi Feb 24, 2023
3f192dc
Merge pull request #67037 from dotnet/revert-67030-disablePreviewDiag…
sharwell Feb 24, 2023
8b75fa0
Change helper type to be a record
CyrusNajmabadi Feb 24, 2023
11402f3
Remove unused option
CyrusNajmabadi Feb 24, 2023
3b9dbde
Avoid deep recursion while emitting deeply nested logical conditions …
AlekseyTs Feb 24, 2023
527c792
Minor source build fixes (#67028)
Feb 24, 2023
0d29ea6
Do not register task list analyzer if solution-crawler is explicitly off
CyrusNajmabadi Feb 24, 2023
e0752a5
Only do reanalysis if solution crawler is enabled
CyrusNajmabadi Feb 24, 2023
3aa2c51
Merge pull request #66959 from DoctorKrolic/completions-in-range-expr…
CyrusNajmabadi Feb 24, 2023
a9f4852
Fix issue in 'use pattern matching'
CyrusNajmabadi Feb 24, 2023
e14d781
Merge pull request #67043 from CyrusNajmabadi/disableCrawler2
CyrusNajmabadi Feb 24, 2023
9aab344
Fix Selection Tracking In Rename (#67031)
ryzngard Feb 24, 2023
f94af1b
Merge pull request #67042 from CyrusNajmabadi/simplifyTYpe
CyrusNajmabadi Feb 25, 2023
e9077ba
Merge branch 'main' into makeMemberReadOnly2
CyrusNajmabadi Feb 25, 2023
2e77728
Merge pull request #67046 from CyrusNajmabadi/solutionCrawlerDiagnost…
CyrusNajmabadi Feb 25, 2023
741770b
Merge pull request #67045 from CyrusNajmabadi/solutionCrawlerTaskList
CyrusNajmabadi Feb 25, 2023
96976ae
Fix marshalability of IWorkspaceProject.StartBatchAsync
jasonmalinowski Feb 25, 2023
d348e79
Move "UseDeconstruction" to `VerifyCS`
DoctorKrolic Feb 25, 2023
c39716b
Use raw strings
DoctorKrolic Feb 25, 2023
62a827b
Filter source generator diagnostics by `SuppressMessageAttribute` (#6…
jjonescz Feb 25, 2023
3a37011
Apply suggestions from code review
CyrusNajmabadi Feb 25, 2023
cfbb25f
Throttle designer attribute scanning, and avoid creating compilations
CyrusNajmabadi Feb 25, 2023
921d7f0
Simplify
CyrusNajmabadi Feb 25, 2023
f714530
Simplify
CyrusNajmabadi Feb 25, 2023
482ae85
Simplify
CyrusNajmabadi Feb 25, 2023
286d4ed
Merge pull request #67048 from jasonmalinowski/fix-batch-api
jasonmalinowski Feb 25, 2023
647cef8
Simplify and delay more work
CyrusNajmabadi Feb 25, 2023
cff1313
Simplify
CyrusNajmabadi Feb 25, 2023
a9cbbf9
NRT
CyrusNajmabadi Feb 25, 2023
bae9787
Simplify
CyrusNajmabadi Feb 25, 2023
ec21669
Inline helper
CyrusNajmabadi Feb 25, 2023
8155ce3
simplify
CyrusNajmabadi Feb 25, 2023
040d7c1
Up the priority of the 'fix formatting' fixer to 'high'
CyrusNajmabadi Feb 25, 2023
13d1633
Layers
CyrusNajmabadi Feb 26, 2023
ac8c66c
Fix
CyrusNajmabadi Feb 26, 2023
6df5d6a
Rename file
CyrusNajmabadi Feb 26, 2023
092a912
Update tests to raw strings
CyrusNajmabadi Feb 26, 2023
85709b2
Add tests
CyrusNajmabadi Feb 26, 2023
2d02e8d
Simplify
CyrusNajmabadi Feb 26, 2023
11ef013
In progress
CyrusNajmabadi Feb 26, 2023
ddb68fe
Working
CyrusNajmabadi Feb 26, 2023
df348e3
In progress
CyrusNajmabadi Feb 26, 2023
1bce763
Simplify
CyrusNajmabadi Feb 26, 2023
1c56bca
Inline
CyrusNajmabadi Feb 26, 2023
c4fb539
Spelling
CyrusNajmabadi Feb 26, 2023
8f47c4c
Fix
CyrusNajmabadi Feb 26, 2023
a84ea8b
Support offering the cleanup option on strings with trailing newline …
CyrusNajmabadi Feb 26, 2023
a97d5cd
Improve fix all behavior
CyrusNajmabadi Feb 26, 2023
b0af744
Merge remote-tracking branch 'upstream/main' into nullableQI
CyrusNajmabadi Feb 26, 2023
202a3f0
Updat test
CyrusNajmabadi Feb 26, 2023
d7a9f37
Add docs
CyrusNajmabadi Feb 26, 2023
0af35c8
warning
CyrusNajmabadi Feb 26, 2023
87debae
Merge pull request #66877 from CyrusNajmabadi/nullableQI
CyrusNajmabadi Feb 26, 2023
bd5b9f9
Merge remote-tracking branch 'upstream/main' into designerAttributeWork
CyrusNajmabadi Feb 26, 2023
d246bcf
Add comments
CyrusNajmabadi Feb 26, 2023
4641f2b
Merge pull request #67056 from CyrusNajmabadi/designerAttributeWork
CyrusNajmabadi Feb 26, 2023
b7f66d5
Use frozen semantics when computing designer attributes
CyrusNajmabadi Feb 26, 2023
2b5bcf3
Freeze first
CyrusNajmabadi Feb 26, 2023
181c188
Freeze before
CyrusNajmabadi Feb 26, 2023
5456887
Add comment
CyrusNajmabadi Feb 26, 2023
6f0879d
Add additional optimization
CyrusNajmabadi Feb 26, 2023
11f37e9
Disable frozen partial for remote inheritance margin
CyrusNajmabadi Feb 26, 2023
477b19c
[Lightbulb Perf] Improve the caching logic in OOP DiagnosticComputer
mavasani Feb 27, 2023
c53ec67
Merge pull request #67063 from CyrusNajmabadi/oopFrozen
CyrusNajmabadi Feb 27, 2023
aede139
Extract remote keep-alive code into its own component
CyrusNajmabadi Feb 27, 2023
0285f64
Merge pull request #66988 from CyrusNajmabadi/sigHelpInProgress
CyrusNajmabadi Feb 27, 2023
d345ab0
Update the lightbulb population code to keep a solution-snapshot pinn…
CyrusNajmabadi Feb 27, 2023
d9de296
Exclude CSharp.EditorFeature from vs_perf_designtime_ide_searchtest
genlu Feb 27, 2023
de2c809
Merge pull request #66935 from sharwell/parameterize-tests
sharwell Feb 27, 2023
7c05a78
Merge pull request #67058 from CyrusNajmabadi/formattingPri
CyrusNajmabadi Feb 27, 2023
e3d76d0
Merge pull request #66957 from CyrusNajmabadi/makeMemberReadOnly2
CyrusNajmabadi Feb 27, 2023
02ee812
Merge pull request #67052 from DoctorKrolic/move-to-verifycs-tuple
CyrusNajmabadi Feb 27, 2023
6960e05
Merge pull request #67076 from genlu/FixOptProf
genlu Feb 28, 2023
6757c56
Merge pull request #67060 from CyrusNajmabadi/convertRawFix
CyrusNajmabadi Feb 28, 2023
22bdff5
Merge pull request #67073 from CyrusNajmabadi/remoteKeepAlive
sharwell Feb 28, 2023
10de0be
Address feedback and revert try/catch removal which uncovered a bug i…
mavasani Feb 28, 2023
e260ded
Rename options to editorconfig like name (#66899)
Cosifne Feb 28, 2023
6c98e5c
Merge pull request #67068 from mavasani/DiagnosticComputerCaching
mavasani Feb 28, 2023
bc9f49e
Bump up priority for formatting analyzer
mavasani Feb 28, 2023
0b24f6b
Merge pull request #67093 from mavasani/FormattingAnalyzerPriority
mavasani Feb 28, 2023
3f882b6
Update src/Analyzers/CSharp/Analyzers/UsePatternMatching/UsePatternMa…
CyrusNajmabadi Feb 28, 2023
1bea965
Merge pull request #67004 from CyrusNajmabadi/addParameterSpan
CyrusNajmabadi Feb 28, 2023
7fae245
Fix crash of property snippets after accessibility modifier (#67054)
DoctorKrolic Feb 28, 2023
3d7fca6
Update to latest bin log reader.
gundermanc Feb 28, 2023
024a35f
Merge pull request #67047 from CyrusNajmabadi/usePatternFix
CyrusNajmabadi Feb 28, 2023
c94b8ca
Local state tracing instrumentation (#66768)
tmat Feb 28, 2023
1a642d9
Merge pull request #67085 from gundermanc/dev/chgund/UpdateStructured…
jasonmalinowski Feb 28, 2023
4e701c6
Merge 'dotnet/main' into PrimaryConstructors
AlekseyTs Feb 28, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
32 changes: 16 additions & 16 deletions Roslyn.sln
Original file line number Diff line number Diff line change
Expand Up @@ -631,22 +631,22 @@ Global
{5F8D2414-064A-4B3A-9B42-8E2A04246BE5}.Debug|Any CPU.Build.0 = Debug|Any CPU
{5F8D2414-064A-4B3A-9B42-8E2A04246BE5}.Release|Any CPU.ActiveCfg = Release|Any CPU
{5F8D2414-064A-4B3A-9B42-8E2A04246BE5}.Release|Any CPU.Build.0 = Release|Any CPU
{02459936-CD2C-4F61-B671-5C518F2A3DDC}.Debug|Any CPU.ActiveCfg = Debug|x64
{02459936-CD2C-4F61-B671-5C518F2A3DDC}.Debug|Any CPU.Build.0 = Debug|x64
{02459936-CD2C-4F61-B671-5C518F2A3DDC}.Release|Any CPU.ActiveCfg = Release|x64
{02459936-CD2C-4F61-B671-5C518F2A3DDC}.Release|Any CPU.Build.0 = Release|x64
{288089C5-8721-458E-BE3E-78990DAB5E2E}.Debug|Any CPU.ActiveCfg = Debug|x64
{288089C5-8721-458E-BE3E-78990DAB5E2E}.Debug|Any CPU.Build.0 = Debug|x64
{288089C5-8721-458E-BE3E-78990DAB5E2E}.Release|Any CPU.ActiveCfg = Release|x64
{288089C5-8721-458E-BE3E-78990DAB5E2E}.Release|Any CPU.Build.0 = Release|x64
{02459936-CD2C-4F61-B671-5C518F2A3DDC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{02459936-CD2C-4F61-B671-5C518F2A3DDC}.Debug|Any CPU.Build.0 = Debug|Any CPU
{02459936-CD2C-4F61-B671-5C518F2A3DDC}.Release|Any CPU.ActiveCfg = Release|Any CPU
{02459936-CD2C-4F61-B671-5C518F2A3DDC}.Release|Any CPU.Build.0 = Release|Any CPU
{288089C5-8721-458E-BE3E-78990DAB5E2E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{288089C5-8721-458E-BE3E-78990DAB5E2E}.Debug|Any CPU.Build.0 = Debug|Any CPU
{288089C5-8721-458E-BE3E-78990DAB5E2E}.Release|Any CPU.ActiveCfg = Release|Any CPU
{288089C5-8721-458E-BE3E-78990DAB5E2E}.Release|Any CPU.Build.0 = Release|Any CPU
{288089C5-8721-458E-BE3E-78990DAB5E2D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{288089C5-8721-458E-BE3E-78990DAB5E2D}.Debug|Any CPU.Build.0 = Debug|Any CPU
{288089C5-8721-458E-BE3E-78990DAB5E2D}.Release|Any CPU.ActiveCfg = Release|Any CPU
{288089C5-8721-458E-BE3E-78990DAB5E2D}.Release|Any CPU.Build.0 = Release|Any CPU
{6AA96934-D6B7-4CC8-990D-DB6B9DD56E34}.Debug|Any CPU.ActiveCfg = Debug|x64
{6AA96934-D6B7-4CC8-990D-DB6B9DD56E34}.Debug|Any CPU.Build.0 = Debug|x64
{6AA96934-D6B7-4CC8-990D-DB6B9DD56E34}.Release|Any CPU.ActiveCfg = Release|x64
{6AA96934-D6B7-4CC8-990D-DB6B9DD56E34}.Release|Any CPU.Build.0 = Release|x64
{6AA96934-D6B7-4CC8-990D-DB6B9DD56E34}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{6AA96934-D6B7-4CC8-990D-DB6B9DD56E34}.Debug|Any CPU.Build.0 = Debug|Any CPU
{6AA96934-D6B7-4CC8-990D-DB6B9DD56E34}.Release|Any CPU.ActiveCfg = Release|Any CPU
{6AA96934-D6B7-4CC8-990D-DB6B9DD56E34}.Release|Any CPU.Build.0 = Release|Any CPU
{C50166F1-BABC-40A9-95EB-8200080CD701}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{C50166F1-BABC-40A9-95EB-8200080CD701}.Debug|Any CPU.Build.0 = Debug|Any CPU
{C50166F1-BABC-40A9-95EB-8200080CD701}.Release|Any CPU.ActiveCfg = Release|Any CPU
Expand All @@ -659,10 +659,10 @@ Global
{E3FDC65F-568D-4E2D-A093-5132FD3793B7}.Debug|Any CPU.Build.0 = Debug|Any CPU
{E3FDC65F-568D-4E2D-A093-5132FD3793B7}.Release|Any CPU.ActiveCfg = Release|Any CPU
{E3FDC65F-568D-4E2D-A093-5132FD3793B7}.Release|Any CPU.Build.0 = Release|Any CPU
{909B656F-6095-4AC2-A5AB-C3F032315C45}.Debug|Any CPU.ActiveCfg = Debug|x64
{909B656F-6095-4AC2-A5AB-C3F032315C45}.Debug|Any CPU.Build.0 = Debug|x64
{909B656F-6095-4AC2-A5AB-C3F032315C45}.Release|Any CPU.ActiveCfg = Release|x64
{909B656F-6095-4AC2-A5AB-C3F032315C45}.Release|Any CPU.Build.0 = Release|x64
{909B656F-6095-4AC2-A5AB-C3F032315C45}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{909B656F-6095-4AC2-A5AB-C3F032315C45}.Debug|Any CPU.Build.0 = Debug|Any CPU
{909B656F-6095-4AC2-A5AB-C3F032315C45}.Release|Any CPU.ActiveCfg = Release|Any CPU
{909B656F-6095-4AC2-A5AB-C3F032315C45}.Release|Any CPU.Build.0 = Release|Any CPU
{2E87FA96-50BB-4607-8676-46521599F998}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{2E87FA96-50BB-4607-8676-46521599F998}.Debug|Any CPU.Build.0 = Debug|Any CPU
{2E87FA96-50BB-4607-8676-46521599F998}.Release|Any CPU.ActiveCfg = Release|Any CPU
Expand Down
3 changes: 2 additions & 1 deletion azure-pipelines-integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ pr:
- CONTRIBUTING.md
- README.md
- src/Compilers/*
- src/Features/LanguageServer/Microsoft.CommonLanguageServerProtocol.Framework/README.md

parameters:
- name: poolName
Expand All @@ -55,7 +56,7 @@ parameters:
- name: queueName
displayName: Queue Name
type: string
default: windows.vs2022.scout.amd64.open
default: windows.vs2022.amd64.open
values:
- windows.vs2022.amd64.open
- windows.vs2022.scout.amd64.open
Expand Down
1 change: 1 addition & 0 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ pr:
exclude:
- docs/*
- eng/config/PublishData.json
- src/Features/LanguageServer/Microsoft.CommonLanguageServerProtocol.Framework/README.md
- .vscode/*
- .github/*
- .devcontainer/*
Expand Down
2 changes: 1 addition & 1 deletion docs/Language Feature Status.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ efforts behind them.
| [Lambda default parameters](https://github.com/dotnet/csharplang/issues/6051) | [lambda-default-parameters](https://github.com/dotnet/roslyn/tree/features/lambda-default-parameters) | [Merged into 17.5p2](https://github.com/dotnet/roslyn/issues/62485) | [adamperlin](https://github.com/adamperlin), [jjonescz](https://github.com/jjonescz) | [333fred](https://github.com/333fred), [cston](https://github.com/cston) | [captainsafia](https://github.com/captainsafia) |
| [Default in deconstruction](https://github.com/dotnet/roslyn/pull/25562) | [decon-default](https://github.com/dotnet/roslyn/tree/features/decon-default) | [In Progress](https://github.com/dotnet/roslyn/issues/25559) | [jcouv](https://github.com/jcouv) | [gafter](https://github.com/gafter) | [jcouv](https://github.com/jcouv) |
| [Collection Literals](https://github.com/dotnet/csharplang/issues/5354) | [CollectionLiterals](https://github.com/dotnet/roslyn/tree/features/CollectionLiterals) | [In Progress](https://github.com/dotnet/roslyn/issues/66418) | [cston](https://github.com/cston) | [333fred](https://github.com/333fred), [RikkiGibson](https://github.com/RikkiGibson) | [CyrusNajmabadi](https://github.com/CyrusNajmabadi) |
| [Roles](https://github.com/dotnet/csharplang/issues/5497) | [roles](https://github.com/dotnet/roslyn/tree/features/roles) | [In Progress](https://github.com/dotnet/roslyn/issues/66722) | [jcouv](https://github.com/jcouv) | TBD | [MadsTorgersen](https://github.com/MadsTorgersen) |
| [Roles/Extensions](https://github.com/dotnet/csharplang/issues/5497) | [roles](https://github.com/dotnet/roslyn/tree/features/roles) | [In Progress](https://github.com/dotnet/roslyn/issues/66722) | [jcouv](https://github.com/jcouv) | [AlekseyTs](https://github.com/AlekseyTs), [333fred](https://github.com/333fred) | [MadsTorgersen](https://github.com/MadsTorgersen) |

# C# 11.0

Expand Down
4 changes: 2 additions & 2 deletions eng/Versions.props
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
<MicrosoftVisualStudioLanguageServerClientPackagesVersion>17.3.3101</MicrosoftVisualStudioLanguageServerClientPackagesVersion>
<MicrosoftVisualStudioLanguageServerProtocolPackagesVersion>17.5.20-preview</MicrosoftVisualStudioLanguageServerProtocolPackagesVersion>
<MicrosoftVisualStudioShellPackagesVersion>17.5.0-preview-2-33117-317</MicrosoftVisualStudioShellPackagesVersion>
<RefOnlyMicrosoftBuildPackagesVersion>16.5.0</RefOnlyMicrosoftBuildPackagesVersion>
<RefOnlyMicrosoftBuildPackagesVersion>16.10.0</RefOnlyMicrosoftBuildPackagesVersion>
<!-- The version of Roslyn we build Source Generators against that are built in this
repository. This must be lower than MicrosoftNetCompilersToolsetVersion,
but not higher than our minimum dogfoodable Visual Studio version, or else
Expand Down Expand Up @@ -203,7 +203,7 @@
<MicrosoftVisualStudioWorkspaceVSIntegrationVersion>17.1.11-preview-0002</MicrosoftVisualStudioWorkspaceVSIntegrationVersion>
<MicrosoftWin32PrimitivesVersion>4.3.0</MicrosoftWin32PrimitivesVersion>
<MicrosoftWin32RegistryVersion>5.0.0</MicrosoftWin32RegistryVersion>
<MSBuildStructuredLoggerVersion>2.1.500</MSBuildStructuredLoggerVersion>
<MSBuildStructuredLoggerVersion>2.1.787</MSBuildStructuredLoggerVersion>
<MDbgVersion>0.1.0</MDbgVersion>
<MonoOptionsVersion>6.6.0.161</MonoOptionsVersion>
<MoqVersion>4.10.1</MoqVersion>
Expand Down
4 changes: 4 additions & 0 deletions eng/build.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,10 @@ function Process-Arguments() {
$script:restore = $true
}

if ($sourceBuild) {
$script:msbuildEngine = "dotnet"
}

foreach ($property in $properties) {
if (!$property.StartsWith("/p:", "InvariantCultureIgnoreCase")) {
Write-Host "Invalid argument: $property"
Expand Down
2 changes: 1 addition & 1 deletion eng/config/OptProf.json
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@
},
{
"filename": "/Microsoft.CodeAnalysis.CSharp.EditorFeatures.dll",
"testCases":[ "VSPE.OptProfTests.vs_asl_cs_scenario", "VSPE.OptProfTests.vs_perf_designtime_editor_intellisense_globalcompletionlist_cs", "VSPE.OptProfTests.vs_perf_designtime_ide_searchtest", "VSPE.OptProfTests.DDRIT_RPS_ManagedLangs_Typing", "VSPE.OptProfTests.DDRIT_RPS_ManagedLangs_Debug" ]
"testCases":[ "VSPE.OptProfTests.vs_asl_cs_scenario", "VSPE.OptProfTests.vs_perf_designtime_editor_intellisense_globalcompletionlist_cs", "VSPE.OptProfTests.DDRIT_RPS_ManagedLangs_Typing", "VSPE.OptProfTests.DDRIT_RPS_ManagedLangs_Debug" ]
},
{
"filename": "/Microsoft.CodeAnalysis.Features.dll",
Expand Down
1 change: 1 addition & 0 deletions eng/targets/Services.props
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
<ServiceHubService Include="Microsoft.VisualStudio.LanguageServices.SemanticClassification" ClassName="Microsoft.CodeAnalysis.Remote.RemoteSemanticClassificationService+Factory" />
<ServiceHubService Include="Microsoft.VisualStudio.LanguageServices.DocumentHighlights" ClassName="Microsoft.CodeAnalysis.Remote.RemoteDocumentHighlightsService+Factory" />
<ServiceHubService Include="Microsoft.VisualStudio.LanguageServices.EncapsulateField" ClassName="Microsoft.CodeAnalysis.Remote.RemoteEncapsulateFieldService+Factory" />
<ServiceHubService Include="Microsoft.VisualStudio.LanguageServices.KeepAlive" ClassName="Microsoft.CodeAnalysis.Remote.RemoteKeepAliveService+Factory" />
<ServiceHubService Include="Microsoft.VisualStudio.LanguageServices.Renamer" ClassName="Microsoft.CodeAnalysis.Remote.RemoteRenamerService+Factory" />
<ServiceHubService Include="Microsoft.VisualStudio.LanguageServices.ConvertTupleToStructCodeRefactoring" ClassName="Microsoft.CodeAnalysis.Remote.RemoteConvertTupleToStructCodeRefactoringService+Factory" />
<ServiceHubService Include="Microsoft.VisualStudio.LanguageServices.SymbolFinder" ClassName="Microsoft.CodeAnalysis.Remote.RemoteSymbolFinderService+Factory" />
Expand Down
1 change: 1 addition & 0 deletions src/Analyzers/CSharp/Analyzers/CSharpAnalyzers.projitems
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
<Compile Include="$(MSBuildThisFileDirectory)ForEachCast\CSharpForEachCastDiagnosticAnalyzer.cs" />
<Compile Include="$(MSBuildThisFileDirectory)Formatting\CSharpFormattingAnalyzer.cs" />
<Compile Include="$(MSBuildThisFileDirectory)MakeFieldReadonly\CSharpMakeFieldReadonlyDiagnosticAnalyzer.cs" />
<Compile Include="$(MSBuildThisFileDirectory)MakeStructMemberReadOnly\CSharpMakeStructMemberReadOnlyAnalyzer.cs" />
<Compile Include="$(MSBuildThisFileDirectory)NewLines\ArrowExpressionClausePlacement\ArrowExpressionClausePlacementDiagnosticAnalyzer.cs" />
<Compile Include="$(MSBuildThisFileDirectory)NewLines\ConditionalExpressionPlacement\ConditionalExpressionPlacementDiagnosticAnalyzer.cs" />
<Compile Include="$(MSBuildThisFileDirectory)NewLines\ConsecutiveBracePlacement\ConsecutiveBracePlacementDiagnosticAnalyzer.cs" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -404,4 +404,12 @@
<data name="Use_nameof" xml:space="preserve">
<value>Use 'nameof'</value>
</data>
<data name="Make_member_readonly" xml:space="preserve">
<value>Make member 'readonly'</value>
<comment>{Locked="readonly"} "readonly" is a C# keyword and should not be localized.</comment>
</data>
<data name="Member can be made readonly" xml:space="preserve">
<value>Member can be made 'readonly'</value>
<comment>{Locked="readonly"} "readonly" is a C# keyword and should not be localized.</comment>
</data>
</root>
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ internal CSharpCodeGenerationOptions GetCodeGenerationOptions()

public CodeStyleOption2<ExpressionBodyPreference> PreferExpressionBodiedLambdas => GetOption(CSharpCodeStyleOptions.PreferExpressionBodiedLambdas, FallbackCodeStyleOptions.PreferExpressionBodiedLambdas);
public CodeStyleOption2<bool> PreferReadOnlyStruct => GetOption(CSharpCodeStyleOptions.PreferReadOnlyStruct, FallbackCodeStyleOptions.PreferReadOnlyStruct);
public CodeStyleOption2<bool> PreferReadOnlyStructMember => GetOption(CSharpCodeStyleOptions.PreferReadOnlyStructMember, FallbackCodeStyleOptions.PreferReadOnlyStructMember);
public CodeStyleOption2<bool> PreferStaticLocalFunction => GetOption(CSharpCodeStyleOptions.PreferStaticLocalFunction, FallbackCodeStyleOptions.PreferStaticLocalFunction);

private TValue GetOption<TValue>(Option2<TValue> option, TValue defaultValue)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,8 @@ methodDeclaration.Parent is not TypeDeclarationSyntax containingTypeDeclaration
return false;

// If the user renamed the 'args' parameter, we can't convert to top level statements.
if (methodDeclaration.ParameterList.Parameters.Count == 1 &&
methodDeclaration.ParameterList.Parameters[0].Identifier.ValueText != "args")
{
if (methodDeclaration.ParameterList.Parameters is [{ Identifier.ValueText: not "args" }])
return false;
}

// Found a suitable candidate. See if this matches the entrypoint the compiler has actually chosen.
var entryPointMethod = semanticModel.Compilation.GetEntryPoint(cancellationToken);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,7 @@
using System.Collections.Immutable;
using System.Diagnostics.CodeAnalysis;
using System.Linq;
using Microsoft.CodeAnalysis.CSharp.Extensions;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.Shared.Extensions;

namespace Microsoft.CodeAnalysis.CSharp.MakeLocalFunctionStatic
{
Expand All @@ -24,9 +22,10 @@ private static bool TryGetDataFlowAnalysis(LocalFunctionStatementSyntax localFun

private static bool CanBeCalledFromStaticContext(LocalFunctionStatementSyntax localFunction, DataFlowAnalysis dataFlow)
{
// If other local functions are called the it can't be made static unles the
// are static, or the local function is recursive, or its calling a child local function
return !dataFlow.UsedLocalFunctions.Any(static (lf, localFunction) => !lf.IsStatic && !IsChildOrSelf(localFunction, lf), localFunction);
// If other local functions are called the it can't be made static unless the are static, or the local
// function is recursive, or its calling a child local function
return !dataFlow.UsedLocalFunctions.Any(static (usedLocalFunction, localFunctionStatement) =>
!usedLocalFunction.IsStatic && !IsChildOrSelf(localFunctionStatement, usedLocalFunction), localFunction);

static bool IsChildOrSelf(LocalFunctionStatementSyntax containingLocalFunction, ISymbol calledLocationFunction)
{
Expand All @@ -36,21 +35,18 @@ static bool IsChildOrSelf(LocalFunctionStatementSyntax containingLocalFunction,
}
}

private static bool HasCapturesThatArentThis(ImmutableArray<ISymbol> captures)
=> !captures.IsEmpty && !captures.Any(static s => s.IsThisParameter());

public static bool CanMakeLocalFunctionStaticBecauseNoCaptures(LocalFunctionStatementSyntax localFunction, SemanticModel semanticModel)
=> TryGetDataFlowAnalysis(localFunction, semanticModel, out var dataFLow)
&& CanBeCalledFromStaticContext(localFunction, dataFLow)
&& dataFLow.CapturedInside.IsEmpty;
=> TryGetDataFlowAnalysis(localFunction, semanticModel, out var dataFlow)
&& CanBeCalledFromStaticContext(localFunction, dataFlow)
&& dataFlow.CapturedInside.IsEmpty;

public static bool CanMakeLocalFunctionStaticByRefactoringCaptures(LocalFunctionStatementSyntax localFunction, SemanticModel semanticModel, out ImmutableArray<ISymbol> captures)
{
if (TryGetDataFlowAnalysis(localFunction, semanticModel, out var dataFLow) &&
CanBeCalledFromStaticContext(localFunction, dataFLow) &&
HasCapturesThatArentThis(dataFLow.CapturedInside))
if (TryGetDataFlowAnalysis(localFunction, semanticModel, out var dataFlow) &&
CanBeCalledFromStaticContext(localFunction, dataFlow) &&
!dataFlow.CapturedInside.IsEmpty)
{
captures = dataFLow.CapturedInside;
captures = dataFlow.CapturedInside;
return true;
}

Expand Down
Loading