by Waterluvian · 4y ago · 0 comments
You define a Python function interface but populate it with a string of C code.
def add(x: int, y: int) -> int:
""" // c code
int x, y
return x + y
"""
And it compiles it and turns it into a C extension?That's...horrifying yet amazing.