Minor refactor of Stream#decode