From 142004d7f31ad2eee58dc6c9bdec7bdcc530cf58 Mon Sep 17 00:00:00 2001 From: Rusty Wagner Date: Tue, 10 Dec 2019 16:16:33 -0500 Subject: Immutable type/struct/enum objects, allowing deduplication for reduced memory usage. In C++ API, modifying or creating types, structures, or enumerations should be done with the new TypeBuilder, StructureBuilder, and EnumerationBuilder objects, then converted to a final Type, Structure, or Enumeration object using the Finalize method once the modifications are complete. When modifying structures or enumerations inside existing types, use the WithReplacedStructure or WithReplacedEnumeration methods on the root type object and reregister the type to use the modified object. In Python API, types, structures, and enumerations can be created as in previous versions, but the objects become immutable once they are passed to a method. To modify an existing type, structure, or enumeration, use the mutable_copy() method. When modifying structures or enumerations, replace the modified object in the Type with the with_replaced_structure() or with_replaced_enumeration() methods. --- python/settings.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'python/settings.py') diff --git a/python/settings.py b/python/settings.py index fec4023d..f81c8eef 100644 --- a/python/settings.py +++ b/python/settings.py @@ -65,7 +65,7 @@ class Settings(object): def __init__(self, instance_id = "default", handle = None): if handle is None: - if instance_id is None or instance_id is "": + if instance_id is None or instance_id == "": instance_id = "default" self._instance_id = instance_id if instance_id == "default": -- cgit v1.3.1