1.1 --- a/lib/__builtins__/sequence.py Tue Jul 03 15:58:44 2018 +0200
1.2 +++ b/lib/__builtins__/sequence.py Tue Jul 03 16:02:02 2018 +0200
1.3 @@ -20,7 +20,7 @@
1.4 """
1.5
1.6 from __builtins__.int import maxint
1.7 -from native import isinstance as _isinstance, is_int
1.8 +from native import isinstance as _isinstance, is_int, list_element
1.9
1.10 class itemaccess:
1.11
1.12 @@ -255,6 +255,19 @@
1.13
1.14 # __iter__(self)
1.15
1.16 +class unpackable(sequence):
1.17 +
1.18 + "Class for list and tuple unpacking."
1.19 +
1.20 + def __get_single_item_unchecked__(self, index):
1.21 +
1.22 + """
1.23 + NOTE: Should restrict this to internal translator use.
1.24 + NOTE: This also uses implementation-specific access.
1.25 + """
1.26 +
1.27 + return list_element(self.__data__, index)
1.28 +
1.29 def _get_absolute_index(index, length):
1.30
1.31 """