This commit is contained in:
aothms
2015-11-10 11:16:00 +01:00
parent d076fa588b
commit 579d3713fd
10 changed files with 875 additions and 10 deletions
+9 -1
View File
@@ -64,7 +64,11 @@ class SchemaClass:
for cpp_type, collection in collections_by_type:
for name in collection.keys():
statements.append('%(cpp_type)s* %(name)s_type = 0;' % locals())
statements.append('#ifdef _MSC_VER' )
statements.append('#pragma optimize("", off)')
statements.append('#endif' )
statements.append('schema_definition* populate_schema() {')
emitted_types = set()
@@ -145,6 +149,10 @@ class SchemaClass:
statements.extend(('}',''))
statements.append('#ifdef _MSC_VER' )
statements.append('#pragma optimize("", on)')
statements.append('#endif' )
statements.extend(('const schema_definition& get_schema() {',
'',
' static const schema_definition* s = populate_schema();',