Serpent 2.0: Storage data structure definition

cybercocyberco Member Posts: 20
Serpent 2.0 introduced a new storage data structure that is not valid Python. I know that Serpent IS not Python, but for experienced Python developers this (from the wiki) is rather awkward:

data bodies[100](head(eyes[2], nose, mouth), arms[2](fingers[5], elbow), legs[2])

An alternative that would read as valid Python could be:

bodies = 100 * [head[2 * [eye], nose, mouth], 2 * [arm], 2 * [leg]]

Or use '(' if you want tuples (but that looks too much like an invocation to me).
Sign In or Register to comment.