]> Repositories - Adafruit_Blinka-hackapet.git/blob - src/micropython.py
Merge pull request #349 from simallaire/multiple_mcp
[Adafruit_Blinka-hackapet.git] / src / micropython.py
1 """
2 `micropython` - MicroPython Specific Decorator Functions
3 =================================================
4
5 * Author(s): cefn
6 """
7
8
9 def const(x):
10     "Emulate making a constant"
11     return x
12
13
14 def native(f):
15     "Emulate making a native"
16     return f
17
18
19 def viper(f):
20     "User is attempting to use a viper code emitter"
21     raise SyntaxError("invalid micropython decorator")
22
23
24 def asm_thumb(f):
25     "User is attempting to use an inline assembler"
26     raise SyntaxError("invalid micropython decorator")