derive4j / hkt

Higher Kinded Type machinery for Java
BSD 3-Clause "New" or "Revised" License
81 stars 9 forks source link

Anonymous instantiation of __* interfaces is possible #32

Open gneuvill opened 7 years ago

gneuvill commented 7 years ago

This

__2<p, S, A> nasty() {
  return new __2<p, S, A>() {};
}

compiles. It shouldn't.