This page compares three static type checkers for Python. The red background indicates that the checker fails to detect a type error or reports a false positive. Back to start page.
''' ) out.write('') out.write('Input') for checker in checkers: out.write(' | ')
out.write(''.format(html.escape(checker.url)))
out.write(checker.__class__.__name__)
out.write('')
out.write(' ({})'.format(html.escape(checker.version()))) out.write(' |
---|---|
') with open(puzzle) as f: code = f.read() out.write(highlight(code, python_lexer, html_formatter)) error_ok = '# error' in code or '# maybe error' in code no_error_ok = '# error' not in code for checker in checkers: errors = checker_results[checker.__class__.__name__] expected = (errors and error_ok) or (not errors and no_error_ok) out.write(' | '.format('ok' if expected else 'unexpected'))
if errors:
out.write('
(') out.write(issue) out.write(')') out.write(' |