def foreignKey[P, PU, TT <: AbstractTable[_], U] ...
It's not sufficient to document the function's arguments. You also need to document the type variables! Likewise in haskell with code like f . g x . (h (i x) $ j y z) . k $ aNamedVariable
It really isnt' so hard to refactor that into let descriptivelyNamedFunction = (h (i x) $ j y z)
anotherDescriptivelyNamedVariable = descriptivelyNamedFunction . k $ aNamedVariable
in f . g x $ anotherDescriptivelyNamedVariable
It's much larger, but in certain places it prevents so many headaches. It's great that you can put stuff inline, but both communities seem super lax about accepting code that is the opposite of self-documenting.edited for clarity, i hope