xpile 0.1.615

Polyglot transpile workbench (Python/C/C++/Rust/Ruchy/Lean ↔ Rust/Ruchy/PTX/WGSL/SPIR-V) with provable contracts at every layer.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
def show_bool(b: bool) -> str:
    return "%s" % b


def show_float(x: float) -> str:
    return "%s" % x


def both(b: bool, x: float) -> str:
    return "[%s|%s]" % (b, x)


def padded_bool(b: bool) -> str:
    return "%10s" % b