created 2 scala-specific versions of ToString to fix the build