Tweaked special_append() function.