original_string: private function boolishToFlag($value): bool
      {
          switch (true) {
              case 'true' === $value:
              case true === $value:
              case 'yes' === $value:
                  return true;
              case 'no' === $value:
              case 'false' === $value:
              case false === $value:
                  return false;
              default:
                  throw new \InvalidArgumentException('Invalid value for remove-obsolete flag.');
          }
      }
code: private function boolishToFlag($value): bool
      {
          switch (true) {
              case 'true' === $value:
              case true === $value:
              case 'yes' === $value:
                  return true;
              case 'no' === $value:
              case 'false' === $value:
              case false === $value:
                  return false;
              default:
                  throw new \InvalidArgumentException('Invalid value for remove-obsolete flag.');
          }
      }
code_tokens: private function boolishToFlag ( $ value ) : bool { switch ( true ) { case 'true' === $ value : case true === $ value : case 'yes' === $ value : return true ; case 'no' === $ value : case 'false' === $ value : case false === $ value : return false ; default : throw new \ InvalidArgumentException ( 'Invalid value for remove-obsolete flag.' ) ; } }
docstring: Convert the passed value to a bool.
  
  @param string|bool|null $value The value.
  
  @return bool
  
  @throws \InvalidArgumentException When the value can not be converted.
docstring_tokens: Convert the passed value to a bool .