public function assertList($value) { if ($value[0] !== Type::T_LIST) { $this->throwError('expecting list'); } return $value; }