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
I'm developing a WinUI application with Community Toolkit MVVM 8.4.0.
I switched the properties in my application to use the new format. Here's one example:
[ObservableProperty]
public partial bool Returned { get; set; } = returned;
And this is a simplified version of the constructor for the object: public partial class Item(bool returned) : ObservableObject
This all works as expected and compiles fine but all uses of the property elsewhere show the Compiler Error CS0229. In this case it shows: Ambiguity between Item.Returned and Item.Returned.
I only have the one property called Returned.
As I said, it all compiles fine and works correctly but I'm not able to get rid of the error.
Regression
No response
Steps to reproduce
Create a class with the type ObservableObject and create a partial Observable Property. Use it elsewhere in the app.
Example:
public partial class Item(bool returned) {
[ObservableProperty]
public partial bool Returned { get; set; } = returned;
}
Then access the property somewhere else in the app.
Example:
var newItem = new Item(false);
newItem.Returned = true;
This shows the compiler error.
Expected behavior
I would like to remove the false alarm.
Screenshots
IDE and version
VS 2022
IDE version
Version 17.13.1
Nuget packages
CommunityToolkit.Common
CommunityToolkit.Diagnostics
CommunityToolkit.HighPerformance
CommunityToolkit.Mvvm (aka MVVM Toolkit)
Nuget package version(s)
8.4.0
Additional context
No response
Help us help you
Yes, but only if others can assist
The text was updated successfully, but these errors were encountered:
Describe the bug
I'm developing a WinUI application with Community Toolkit MVVM 8.4.0.
I switched the properties in my application to use the new format. Here's one example:
And this is a simplified version of the constructor for the object:
public partial class Item(bool returned) : ObservableObject
This all works as expected and compiles fine but all uses of the property elsewhere show the Compiler Error CS0229. In this case it shows:
Ambiguity between Item.Returned and Item.Returned.
I only have the one property called Returned.
As I said, it all compiles fine and works correctly but I'm not able to get rid of the error.
Regression
No response
Steps to reproduce
Create a class with the type ObservableObject and create a partial Observable Property. Use it elsewhere in the app.
Example:
Then access the property somewhere else in the app.
Example:
This shows the compiler error.
Expected behavior
I would like to remove the false alarm.
Screenshots
IDE and version
VS 2022
IDE version
Version 17.13.1
Nuget packages
Nuget package version(s)
8.4.0
Additional context
No response
Help us help you
Yes, but only if others can assist
The text was updated successfully, but these errors were encountered: