Automatic flushing for Go