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

Generating events for generic class fails due to to constraints order #166

Open
oliverw opened this issue Mar 1, 2023 · 0 comments
Open

Comments

@oliverw
Copy link

oliverw commented Mar 1, 2023

The generated code for the class below fails to compile due to wrong re-ordering of the generic constraints:

public class ContentFlyout<TControl, TModel> : Flyout,
    IDisposable 
    where TControl: ReactiveUserControl<TModel>, new()
    where TModel : ReactiveObject
{
...
}
internal class RxContentFlyoutEvents<TControl, TModel> where TControl : new() , global::ReactiveUI.ReactiveUserControl<TModel>  where TModel : global::ReactiveUI.ReactiveObject 

InstanceEvents.SourceGenerated.cs(4,77,4,80): error CS0401: The new() constraint must be the last constraint specified

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant