HaniiPuppy

super constraint

Sep 20th, 2015
181
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.31 KB | None | 0 0
  1. If I were using the syntax that seems like it should work:
  2.  
  3. public class SomeClass<T>
  4. {
  5.     public SomeClass<SuperT> SomeMethod<SuperT>() where T : SuperT
  6.     {  }
  7. }
  8.  
  9. If I were writing the method in Java:
  10.  
  11. public class SomeClass<T>
  12. {
  13.     public <SuperT super T> SomeClass<SuperT> SomeMethod()
  14.     {  }
  15. }
Advertisement
Add Comment
Please, Sign In to add comment