« Return to Thread: Syntax for generic parameter declaration

Re: Syntax for generic parameter declaration

by Wraith-2 :: Rate this Message:

Reply to Author | View in Thread


Is there a specific reason to follow the c# and VB idioms of declaring
constraints after all the types? IL does this inline for each argument
which could be cleaner and may well be easier to describe in a
grammar. Something like:

public class MyGenericClass[of T1 is struct, T2 is (IComparable,
constructor)]

I can't say i like the brackets much but it needs some way to separate
the generic argument listing mode from the constraint listing mode or
you end up guessing what sort of thing the current identifier is.


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Boo Programming Language" group.
To post to this group, send email to boolang@...
To unsubscribe from this group, send email to boolang-unsubscribe@...
For more options, visit this group at http://groups.google.com/group/boolang
-~----------~----~----~----~------~----~------~--~---

 « Return to Thread: Syntax for generic parameter declaration