making some language changes.
This commit is contained in:
parent
42612456a5
commit
cda5c6534b
@ -3,7 +3,7 @@ from hy.lang.hyobj import HYObject
|
|||||||
|
|
||||||
class HYList(HYObject, list):
|
class HYList(HYObject, list):
|
||||||
def __init__(self, nodes):
|
def __init__(self, nodes):
|
||||||
self += nodes
|
[self.append(node) for node in nodes]
|
||||||
|
|
||||||
def get_children(self):
|
def get_children(self):
|
||||||
return self
|
return self
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
from hy.lang.hyobj import HYObject
|
from hy.lang.hyobj import HYObject
|
||||||
|
|
||||||
|
|
||||||
class HYMap(dict, HYObject):
|
class HYMap(HYObject, dict):
|
||||||
def __init__(self, nodes):
|
def __init__(self, nodes):
|
||||||
for node in nodes:
|
for node in nodes:
|
||||||
self[node] = nodes[node]
|
self[node] = nodes[node]
|
||||||
|
@ -8,6 +8,9 @@ else:
|
|||||||
_str_type = unicode
|
_str_type = unicode
|
||||||
|
|
||||||
|
|
||||||
class HYString(_str_type, HYObject):
|
class HYString(HYObject, _str_type):
|
||||||
def __init__(self, string):
|
def __init__(self, string):
|
||||||
self += string
|
self += string
|
||||||
|
|
||||||
|
def eval(self, ln, *args, **kwargs):
|
||||||
|
return str(self)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user