In the Reference Constraint example, GenericsClassesTest.cs uses the old Lesson class, not the updated LessonWithConstraints one. Is that by design? If so, I think it'd be better to use the new class and let the code fail & showcase the compile-time error (T cannot be int, as T has to be a reference type), as that would show the constraint actually being used.
In the Reference Constraint example, GenericsClassesTest.cs uses the old Lesson class, not the updated LessonWithConstraints one. Is that by design? If so, I think it'd be better to use the new class and let the code fail & showcase the compile-time error (T cannot be int, as T has to be a reference type), as that would show the constraint actually being used.