parameters: (input_api, output_api, source_file_filter=None)
return_statement: return []
docstring: Ensures that Blink code uses WTF's platform macros instead of
      Chromium's. Using the latter has resulted in at least one subtle
      build breakage.
docstring_summary: Ensures that Blink code uses WTF's platform macros instead of
      Chromium's. Using the latter has resulted in at least one subtle
      build breakage.
docstring_tokens: Ensures that Blink code uses WTF s platform macros instead of Chromium s . Using the latter has resulted in at least one subtle build breakage .
function: def _CheckChromiumPlatformMacros(input_api, output_api, source_file_filter=None):
      """Ensures that Blink code uses WTF's platform macros instead of
      Chromium's. Using the latter has resulted in at least one subtle
      build breakage."""
      os_macro_re = input_api.re.compile(r'^\s*#(el)?if.*\bOS_')
      errors = input_api.canned_checks._FindNewViolationsOfRule(
          lambda _, x: not os_macro_re.search(x),
          input_api, source_file_filter)
      errors = ['Found use of Chromium OS_* macro in %s. '
          'Use WTF platform macros instead.' % violation for violation in errors]
      if errors:
          return [output_api.PresubmitPromptWarning('\n'.join(errors))]
      return []
function_tokens: def _CheckChromiumPlatformMacros ( input_api , output_api , source_file_filter = None ) : os_macro_re = input_api . re . compile ( r'^\s*#(el)?if.*\bOS_' ) errors = input_api . canned_checks . _FindNewViolationsOfRule ( lambda _ , x : not os_macro_re . search ( x ) , input_api , source_file_filter ) errors = [ 'Found use of Chromium OS_* macro in %s. ' 'Use WTF platform macros instead.' % violation for violation in errors ] if errors : return [ output_api . PresubmitPromptWarning ( '\n' . join ( errors ) ) ] return [ ]