parameters: (bits)
return_statement: return int_bits
docstring: Return parsed integer value iff the given string conforms to the
      grammar of the window bits extension parameters.
docstring_summary: Return parsed integer value iff the given string conforms to the
      grammar of the window bits extension parameters.
docstring_tokens: Return parsed integer value iff the given string conforms to the grammar of the window bits extension parameters .
function: def _parse_window_bits(bits):
      """Return parsed integer value iff the given string conforms to the
      grammar of the window bits extension parameters.
      """
  
      if bits is None:
          raise ValueError('Value is required')
  
      # For non integer values such as "10.0", ValueError will be raised.
      int_bits = int(bits)
  
      # First condition is to drop leading zero case e.g. "08".
      if bits != str(int_bits) or int_bits < 8 or int_bits > 15:
          raise ValueError('Invalid value: %r' % bits)
  
      return int_bits
function_tokens: def _parse_window_bits ( bits ) : if bits is None : raise ValueError ( 'Value is required' ) # For non integer values such as "10.0", ValueError will be raised. int_bits = int ( bits ) # First condition is to drop leading zero case e.g. "08". if bits != str ( int_bits ) or int_bits < 8 or int_bits > 15 : raise ValueError ( 'Invalid value: %r' % bits ) return int_bits