for (@{$msg->body}){ s/\bblah\b/something/g; print; }