Sergio Pedri
0a2e8edec2
Merge pull request #606 from CommunityToolkit/dev/fix-add-source
...
Fix source generators processing nested/generic types
2023-02-14 05:14:47 -08:00
Sergio Pedri
0ea77c3aae
Add codegen test for filename hints on Roslyn 4.0.1
2023-02-14 13:49:29 +01:00
Sergio Pedri
030c3b3bdb
Add missing readonly field modifiers
2023-02-14 13:48:06 +01:00
Sergio Pedri
1dd1cd1c19
Fix AddSource operations on Roslyn 4.0.1
2023-02-14 13:44:46 +01:00
Sergio Pedri
63ba418b6f
Merge pull request #603 from CommunityToolkit/dev/fix-double-attribute-params
...
Fix forwarded double attribute parameters
2023-02-10 10:30:35 -08:00
Sergio Pedri
b4b2227bd9
Fix forwarded double attribute parameters
2023-02-10 19:01:23 +01:00
Sergio Pedri
af3cb964bd
Merge pull request #587 from CommunityToolkit/dev/resolve-symbols-early
...
Resolve all needed symbols early in analyzers
2023-02-01 13:11:36 -08:00
Sergio Pedri
afad5d2b20
Do base type check early in ClassUsingAttributeInsteadOfInheritanceAnalyzer
2023-02-01 00:30:04 +01:00
Sergio Pedri
857b4b871a
Resolve symbols before registering actions in analyzers
2023-02-01 00:30:04 +01:00
Sergio Pedri
c4d904163b
Add Compilation.TryBuildNamedTypeSymbolMap extension
2023-02-01 00:30:03 +01:00
Sergio Pedri
01efc758a8
Merge pull request #582 from CommunityToolkit/dev/new-property-hooks
...
Add new OnPropertyNameChanging and Changed overloads
2023-01-31 15:29:25 -08:00
Sergio Pedri
845503d7f7
Add codegen test for new partial property hooks
2023-02-01 00:07:45 +01:00
Sergio Pedri
7f4c8800aa
Add functional tests for new generated methods
2023-02-01 00:07:45 +01:00
Sergio Pedri
c684646108
Handle nullability in new hooks with previous value
2023-02-01 00:07:45 +01:00
Sergio Pedri
f07bb2015d
Optimize codegen when hooks are not used
2023-02-01 00:07:45 +01:00
Sergio Pedri
2542767121
Generate calls to new property hook overloads
2023-02-01 00:07:45 +01:00
Sergio Pedri
4350cef5b0
Generate new property hook overloads
2023-02-01 00:07:44 +01:00
Sergio Pedri
e6e0940674
Merge pull request #592 from CommunityToolkit/dev/fix-vb-net-projects
...
Fix build error from VB.NET projects
2023-01-31 05:25:02 -08:00
Sergio Pedri
6a7cc7aa33
Fix build error from VB.NET projects
2023-01-30 15:57:23 +01:00
Sergio Pedri
135ba8581d
Add missing XML docs for property hooks
2023-01-29 12:07:09 +01:00
Sergio Pedri
9127b61673
Merge pull request #588 from CommunityToolkit/dev/attribute-inherit-fixer
...
Add fixer for ClassUsingAttributeInsteadOfInheritanceAnalyzer
2023-01-29 03:03:44 -08:00
Sergio Pedri
a421802ef2
Remove DescendantNodesAndSelf() from code fixer
2023-01-28 13:01:11 +01:00
Sergio Pedri
5fe5e5e59a
Merge pull request #590 from Youssef1313/fix-attribute-inherit-fixer
...
Use SyntaxGenerator and leave trivia handling up to it
2023-01-28 02:18:50 -08:00
Youssef Victor
e1c9bcf6a8
Remove unused parameter
2023-01-28 11:38:56 +02:00
Youssef Victor
6cdf53bc92
Use SyntaxGenerator and leave trivia handling up to it
2023-01-28 11:35:19 +02:00
Sergio Pedri
3b2226bb29
Add draft of ClassUsingAttributeInsteadOfInheritanceCodeFixer tests
2023-01-26 22:55:02 +01:00
Sergio Pedri
9a0113f02a
Add ClassUsingAttributeInsteadOfInheritanceCodeFixer
2023-01-26 22:10:04 +01:00
Sergio Pedri
96f3fad50a
Merge pull request #581 from CommunityToolkit/dev/no-symbols-in-ivp
...
Move two more diagnostics to analyzers
2023-01-26 09:32:04 -08:00
Sergio Pedri
f9ee15653d
Merge pull request #578 from 333fred/fixer
...
Add fixers project and implement a fixer for FieldReferenceForObservablePropertyFieldAnalyzer
2023-01-26 09:30:24 -08:00
Sergio Pedri
e7a79c3c5b
Rename code fixer project to CommunityToolkit.Mvvm.CodeFixers
2023-01-23 16:53:47 +01:00
Sergio Pedri
1690599cdc
Gather all symbols in RegisterCompilationStartAction in new analyzers
2023-01-23 15:41:18 +01:00
Sergio Pedri
c70e973478
Use type symbols for lookup in new analyzers
2023-01-23 14:42:48 +01:00
Sergio Pedri
1be2fa125d
Pack code fixer project in the MVVM Toolkit package
2023-01-23 01:07:22 +01:00
Sergio Pedri
6ee8d7cff7
Update code style to follow repo conventions
2023-01-23 00:49:14 +01:00
Sergio Pedri
b908b3fffd
Define [IVT] in .props file, don't hardcode public key
2023-01-23 00:22:42 +01:00
Fredric Silberberg
78d37ab700
Use specific reference assemblies to resolve test errors, mark fixer shared.
2023-01-22 15:11:53 -08:00
Sergio Pedri
b7f121c2ef
Update unit tests for the two new analyzers
2023-01-22 21:34:37 +01:00
Sergio Pedri
1b02376532
Add InvalidClassLevelNotifyDataErrorInfoAttributeAnalyzer
2023-01-22 21:30:39 +01:00
Sergio Pedri
7c9958cb85
Add InvalidTypeForNotifyPropertyChangedRecipientsError
2023-01-22 21:28:43 +01:00
Fredric Silberberg
441abbbdbc
Add fixers project and implement a fixer for FieldReferenceForObservablePropertyFieldAnalyzer
...
This adds a fixer for MVVMTK0034, that simply swaps the field reference for what will be generated for the property. It leaves the qualification intact, basically just doing a text swap. Because it's very a very simple fixer, the built-in batch fixall provider works just fine and does not need special handling.
While I implemented the fixer and added some tests, I did not actually set up all the msbuild goop for properly packaging this as part of the existing packages (as, frankly, the multi-targeting and msbuild setup in this repo is very complicated and I didn't feel like trying to grok exactly how to add it given the setup). The fixer assembly needs to be put next to the analyzer assemblies. This PR will be editable by maintainers, so feel free to implement this in-place in the PR itself.
Fixes https://github.com/CommunityToolkit/dotnet/issues/577 .
2023-01-21 23:16:11 -08:00
Sergio Pedri
302b8a9d5e
Merge pull request #564 from CommunityToolkit/dev/property-attribute-diagnostic
...
Emit diagnostic for unresolved property: attribute over [ObservableProperty] field
2023-01-16 07:18:41 -08:00
Sergio Pedri
9eb3a05d85
Add unit tests for new attribute diagnostics
2023-01-16 13:21:39 +01:00
Sergio Pedri
88ef4913d2
Add diagnostic for invalid property targeted attributes
2023-01-16 13:13:41 +01:00
Sergio Pedri
3f38be0dcb
Remove unnecessary table from readme file
2023-01-15 19:30:00 +01:00
Sergio Pedri
359e0ab709
Merge pull request #562 from CommunityToolkit/dev/analyzer-diagnostics-fixes
...
Fix diagnostic analyzer documentation/title
2023-01-15 07:43:32 -08:00
Sergio Pedri
03af505b99
Fix MVVMTK0034 diagnostic title
2023-01-15 16:26:52 +01:00
Sergio Pedri
257ed92bd0
Move new diagnostics to 8.1 group
2023-01-15 16:25:50 +01:00
Sergio Pedri
399bf4226a
Merge pull request #561 from CommunityToolkit/dev/strong-messenger-irecipient
...
Add missing StrongReferenceMessenger registration fast path
2023-01-13 13:55:02 -08:00
Sergio Pedri
92e68cf776
Add missing StrongReferenceMessenger registration fast path
2023-01-13 22:35:23 +01:00
Nirmal Guru
3ccdf2b89e
Update Code of Conduct doc
...
Update the Code of Conduct doc to the latest revision from .NET Foundation.
The .NET Foundation's version was last updated in 2020 which was v2.0 revision.
The latest version available from the Contributor Covenant website is v2.1 revision.
#### PermaLinks
1. .NET Foundation's CoC: <https://dotnetfoundation.org/code-of-conduct >.
2. Contributor Covenant v2.0: <https://contributor-covenant.org/version/2/0/code_of_conduct >
3. Contributor Covenant v2.1: <https://contributor-covenant.org/version/2/1/code_of_conduct >
2023-01-13 13:13:35 -08:00