News for hackers. Stuff that matters.
Re:The Next Step for Generics by stickfigure on Wednesday June 17, 2020 @01:08AM (#23548024)
As someone who does a lot of work in Java (which lacks typedef), I feel the opposite. I don't like "stringly typed" APIs where everything is a String or int or whatnot - it's only slightly better than Object; you're basically giving up on typechecking.

With generics or typedefs (or a willingness to create lots of classes), you can be certain you never pass an Id<Foo> someplace that expects an Id<Bar>.

Re:The Next Step for Generics by anoncake on Wednesday June 17, 2020 @01:43AM (#23548198)
Not having typedefs wouldn't be much of an issues if we could at least inherit from String and int (or Integer).