parameters: (self, force=False, ok_status=[0])
return_statement: return version
docstring: Return compiler version, or None if compiler is not available.
  
      Parameters
      ----------
      force : bool, optional
          If True, force a new determination of the version, even if the
          compiler already has a version attribute. Default is False.
      ok_status : list of int, optional
          The list of status values returned by the version look-up process
          for which a version string is returned. If the status value is not
          in `ok_status`, None is returned. Default is ``[0]``.
  
      Returns
      -------
      version : str or None
          Version string, in the format of `distutils.version.LooseVersion`.
docstring_summary: Return compiler version, or None if compiler is not available.
docstring_tokens: Return compiler version or None if compiler is not available .
function: def CCompiler_get_version(self, force=False, ok_status=[0]):
      """
      Return compiler version, or None if compiler is not available.
  
      Parameters
      ----------
      force : bool, optional
          If True, force a new determination of the version, even if the
          compiler already has a version attribute. Default is False.
      ok_status : list of int, optional
          The list of status values returned by the version look-up process
          for which a version string is returned. If the status value is not
          in `ok_status`, None is returned. Default is ``[0]``.
  
      Returns
      -------
      version : str or None
          Version string, in the format of `distutils.version.LooseVersion`.
  
      """
      if not force and hasattr(self,'version'):
          return self.version
      self.find_executables()
      try:
          version_cmd = self.version_cmd
      except AttributeError:
          return None
      if not version_cmd or not version_cmd[0]:
          return None
      try:
          matcher = self.version_match
      except AttributeError:
          try:
              pat = self.version_pattern
          except AttributeError:
              return None
          def matcher(version_string):
              m = re.match(pat, version_string)
              if not m:
                  return None
              version = m.group('version')
              return version
  
      status, output = exec_command(version_cmd,use_tee=0)
  
      version = None
      if status in ok_status:
          version = matcher(output)
          if version:
              version = LooseVersion(version)
      self.version = version
      return version
function_tokens: def CCompiler_get_version ( self , force = False , ok_status = [ 0 ] ) : if not force and hasattr ( self , 'version' ) : return self . version self . find_executables ( ) try : version_cmd = self . version_cmd except AttributeError : return None if not version_cmd or not version_cmd [ 0 ] : return None try : matcher = self . version_match except AttributeError : try : pat = self . version_pattern except AttributeError : return None def matcher ( version_string ) : m = re . match ( pat , version_string ) if not m : return None version = m . group ( 'version' ) return version status , output = exec_command ( version_cmd , use_tee = 0 ) version = None if status in ok_status : version = matcher ( output ) if version : version = LooseVersion ( version ) self . version = version return version