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
{{ message }}
This repository has been archived by the owner on Apr 13, 2023. It is now read-only.
So, thanks to @thradec and #58, in the following code:
void x<T>(T y) {
print(y);
}
I get proposed the quickfix Add generic type constraint 'T satisfies Object'. But there's actually another potential fix,namely to change the parameter type to T&Object, giving us:
void x<T>(T&Object y) {
print(y);
}
The same quick fix is also very relevant for formal attributes, not just for parameters. For example:
class X<T>() {
formal T y;
print(y);
}
The text was updated successfully, but these errors were encountered:
So, thanks to @thradec and #58, in the following code:
I get proposed the quickfix
Add generic type constraint 'T satisfies Object'
. But there's actually another potential fix,namely to change the parameter type toT&Object
, giving us:The same quick fix is also very relevant for formal attributes, not just for parameters. For example:
The text was updated successfully, but these errors were encountered: