Skip to content

Commit

Permalink
Fix direct buffer assignments (#33)
Browse files Browse the repository at this point in the history
  • Loading branch information
a5kin committed Jun 5, 2018
1 parent c445696 commit e144fa3
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions xentica/core/properties.py
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,8 @@ def __get__(self, obj, objtype):
def __set__(self, obj, value):
"""Implement custom logic when property is set as class descriptor."""
self.declare_once()
if not hasattr(value, "code"):
value = DeferredExpression(str(value))
code = "%s = %s;\n" % (self.var_name, value.code)
self._bsca.append_code(code)

Expand Down

0 comments on commit e144fa3

Please sign in to comment.