I think it would be better to have this method directly in ``ScalaSourceFile`` (@dragos, WDYT?)