example use of path-dependent type

this is supported in Scala, but not DOT... not good.