def WriteReformattedCode(filename, reformatted_code, in_place=False, encoding=''):
 if in_place:
  with py3compat.open_with_encoding(filename, mode='w', encoding=encoding) as fd:
   fd.write(reformatted_code)
 else:
  py3compat.EncodeAndWriteToStdout(reformatted_code)

def WriteReformattedCode ( filename , reformatted_code , in_place = False , encoding = '' ) : if in_place : with py3compat . open_with_encoding ( filename , mode = 'w' , encoding = encoding ) as fd : fd . write ( reformatted_code ) else : py3compat . EncodeAndWriteToStdout ( reformatted_code )
emit the reformatted code .