import org.log4s._
class A {
private[this] val logger = getLogger
}
class B[T] {
private[this] val logger = getLogger
}
class C[F[_]] {
private[this] val logger = getLogger
}
A and B compile successfully, but C fails with an error like
[error] file:lines: ? takes no type parameters, expected: one
[error] private[this] val logger = getLogger
[error] ^
[error] one error found
[error] (compile:compileIncremental) Compilation failed
If the call is changed to getLogger(classOf[C[F]]) it works as expected.
A
andB
compile successfully, butC
fails with an error likeIf the call is changed to
getLogger(classOf[C[F]])
it works as expected.