GROOVY-6807: Add a default toString implementation to BaseTemplate