The ~w formatting used before was not printing lists embedded in other terms. This change uses trunc_io to print those terms safely and without potentially introducing linebreaks (like ~p would)