improve printing of kw expressions