<?php ftruncate(resource $stream, int $size): bool
<?php { rewind($this->handle); ftruncate($this->handle, 0); return $this; }
<?php $stream = fopen('php://temp/maxmemory:0', 'r+'); fwrite($stream, 'x'); ftruncate($stream, 0); } return $stream;
<?php $input = fopen('php://temp/maxmemory:0', 'r+'); fwrite($input, 'x'); ftruncate($input, 0); $this->loop->addReadStream($input, $this->expectCallableExactly(2));