def _format_sign(is_negative, spec):
 if is_negative:
  return '-'
 elif (spec['sign'] in ' +'):
  return spec['sign']
 else:
  return ''

def _format_sign ( is_negative , spec ) : if is_negative : return '-' elif ( spec [ 'sign' ] in ' +' ) : return spec [ 'sign' ] else : return ''
determine sign character .