Welcome to mypyc documentation!¶ Mypyc compiles Python modules to C extensions. It uses standard Python type hints to generate fast code. First steps Introduction Why mypyc? Use cases Differences from Cython How does it work Development status Getting started Prerequisites Installation Example program Compiling and running Deleting compiled binary Using setup.py Recommended workflow Next steps Using mypyc Using type annotations Primitive types Primitive containers Native classes Tuple types Union types Trait types Erased types Strict runtime type checking Value and heap types Native integer types Native classes Immutable namespaces Inheritance Class variables Generic native classes Metaclasses Class decorators Deleting attributes Other properties Differences from Python Running compiled modules Type errors prevent compilation Runtime type checking Native classes Primitive types Early binding Pickling and copying objects Monkey patching Stack overflows Final values Unsupported features Compilation units Native operations reference Miscellaneous native operations Operators Functions Method decorators Statements Native integer operations Construction Implicit conversions Operators Statements Native boolean operations Construction Operators Functions Native float operations Construction Operators Functions Native string operations Construction Operators Methods Native list operations Construction Operators Statements Methods Functions Native dict operations Construction Operators Statements Methods Functions Native set operations Construction Operators Methods Functions Native tuple operations Construction Operators Statements Functions Advanced topics Performance tips and tricks Profiling Avoiding slow libraries Type annotations Avoiding slow Python features Using fast native features Adjusting garbage collection Fast interpreter shutdown Work smarter Indices and tables¶ Index Module Index Search Page