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
enumE{x}functionenumThing<Textendsnumber>(){vart: T;varnum: number=t;// Should workvarenumMember: E=t;// Should not work}
Right now both of these are an error. But the number one should work because T is constrained to a number. This is useful because it means T can be a number or any enum type.
The spec and implementation would both need to be updated to allow this.
The text was updated successfully, but these errors were encountered:
Right now both of these are an error. But the number one should work because T is constrained to a number. This is useful because it means T can be a number or any enum type.
The spec and implementation would both need to be updated to allow this.
The text was updated successfully, but these errors were encountered: