2017-05-02 01:42:46 +01:00
|
|
|
"""
|
|
|
|
categories: Core,Functions
|
|
|
|
description: User-defined attributes for functions are not supported
|
|
|
|
cause: MicroPython is highly optimized for memory usage.
|
|
|
|
workaround: Use external dictionary, e.g. ``FUNC_X[f] = 0``.
|
|
|
|
"""
|
2020-03-23 02:26:08 +00:00
|
|
|
|
|
|
|
|
2017-05-02 01:42:46 +01:00
|
|
|
def f():
|
|
|
|
pass
|
|
|
|
|
2020-03-23 02:26:08 +00:00
|
|
|
|
2017-05-02 01:42:46 +01:00
|
|
|
f.x = 0
|
|
|
|
print(f.x)
|