Hacker News new | ask | show | jobs
by slantedview 4082 days ago
> It'd be REALLY nice if I could just say "Hey handler, what's your generic type?

There are better ways of resolving type arguments, such as on Handler implementations, at runtime.

See https://github.com/jhalterman/typetools

1 comments

Right. And now you're pushing what should be a compile-time error to runtime, and slowing down performance with runtime checks to boot.
Indeed, but it allows library authors the ability to write nicer APIs without having to pass Class references around - they can be resolved.