* Inline Assembler for the Unix Port
Invalid micropython decorator on Unix port #4675 \\
https://github.com/micropython/micropython/issues/4675
TL;DR: It boils down to building the desired variant with an additional
define:
#+begin_example
make CFLAGS_EXTRA='-DMICROPY_EMIT_INLINE_THUMB=1' VARIANT=...
#+end_example
Testing with an example from the docs...
#+begin_example
$ cat quad.py
@micropython.asm_thumb
def quad(r0):
b(START)
label(DOUBLE)
add(r0, r0, r0)
bx(lr)
label(START)
bl(DOUBLE)
bl(DOUBLE)
print(quad(10))
$ micropython-standard quad.py
Traceback (most recent call last):
File "quad.py", line 1, in <module>
SyntaxError: invalid micropython decorator
$ micropython-standard+thumb quad.py
40
#+end_example
* Happy(?) End.
--
Take Back Control! -- Mesh The Planet!
Do you GNUS too? -- yeti@tickle-me--but-please-only-over-nntp--club
--- Synchronet 3.19a-Linux NewsLink 1.113