mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-09 17:31:45 +00:00
python 2/3 compatibility: from functools import reduce
This commit is contained in:
@@ -20,11 +20,11 @@
|
||||
import os
|
||||
import functools
|
||||
|
||||
from functools import reduce
|
||||
|
||||
from . import guid
|
||||
from . import ifcopenshell_wrapper
|
||||
|
||||
if hasattr(functools, 'reduce'): reduce = functools.reduce
|
||||
|
||||
class entity_instance(object):
|
||||
def __init__(self, e):
|
||||
super(entity_instance, self).__setattr__('wrapped_data', e)
|
||||
|
||||
@@ -19,6 +19,8 @@
|
||||
|
||||
import string
|
||||
|
||||
from functools import reduce
|
||||
|
||||
chars = string.digits + string.ascii_uppercase + string.ascii_lowercase + '_$'
|
||||
|
||||
def compress(g):
|
||||
|
||||
Reference in New Issue
Block a user