original_string: public function free()
      {
          if (!$this->isFreed()) {
              // Invalidate the memory block by setting its state to FREED.
              $this->setHeader(static::STATE_FREED, 0, 0);
  
              // Request the block to be deleted, then close our local handle.
              $this->memDelete();
              shmop_close($this->handle);
              $this->handle = null;
  
              $this->semaphore->free();
          }
      }
code: public function free()
      {
          if (!$this->isFreed()) {
              // Invalidate the memory block by setting its state to FREED.
              $this->setHeader(static::STATE_FREED, 0, 0);
  
              // Request the block to be deleted, then close our local handle.
              $this->memDelete();
              shmop_close($this->handle);
              $this->handle = null;
  
              $this->semaphore->free();
          }
      }
code_tokens: public function free ( ) { if ( ! $ this -> isFreed ( ) ) { // Invalidate the memory block by setting its state to FREED. $ this -> setHeader ( static :: STATE_FREED , 0 , 0 ) ; // Request the block to be deleted, then close our local handle. $ this -> memDelete ( ) ; shmop_close ( $ this -> handle ) ; $ this -> handle = null ; $ this -> semaphore -> free ( ) ; } }
docstring: Frees the shared object from memory.
  
  The memory containing the shared value will be invalidated. When all
  process disconnect from the object, the shared memory block will be
  destroyed by the OS.
  
  Calling `free()` on an object already freed will have no effect.
docstring_tokens: Frees the shared object from memory .