diff --git a/languages/c/templates/json-types/property-assign.cpp b/languages/c/templates/json-types/property-assign.cpp index 17233fbe..88795136 100644 --- a/languages/c/templates/json-types/property-assign.cpp +++ b/languages/c/templates/json-types/property-assign.cpp @@ -1,3 +1,2 @@ Add(_T("${property}"), &${Property}); ${Property} = other.${Property} - members[${property.raw}] = ${Property} diff --git a/languages/cpp/templates/methods/property.cpp b/languages/cpp/templates/methods/property.cpp index 05bd53de..ce38ebd0 100644 --- a/languages/cpp/templates/methods/property.cpp +++ b/languages/cpp/templates/methods/property.cpp @@ -4,7 +4,7 @@ const string method = _T("${info.title.lowercase}.${method.name}"); ${if.params}JsonObject jsonParameters;${end.if.params} ${if.params}${method.params.serialization}${end.if.params} - ${method.result.json.type} jsonResult; + ${method.result.json} jsonResult; ${method.result.initialization} ${if.params}Firebolt::Error status = FireboltSDK::Properties::Get(method, jsonParameters, jsonResult);${end.if.params} ${if.params.empty}Firebolt::Error status = FireboltSDK::Properties::Get(method, jsonResult);${end.if.params.empty} diff --git a/src/macrofier/types.mjs b/src/macrofier/types.mjs index d0a88544..5fa445f5 100644 --- a/src/macrofier/types.mjs +++ b/src/macrofier/types.mjs @@ -348,10 +348,8 @@ const insertObjectMacros = (content, schema, module, title, property, options) = // don't push properties w/ unsupported types if (type) { const description = getSchemaDescription(prop, module) - const additionalType = typeof prop.type == 'string' ? getPrimitiveType(prop.type, 'additional-types') : null let replacedTemplate = template .replace(/(^\s+)/g, '$1'.repeat(options2.level)) - .replace(/\$\{additional\.type\}/g, additionalType) //C++ - Gives the object type (Ex: Boolean()). Non-AnyOf only .replace(/\$\{property.raw\}/g, name) //Gives the raw RPC propery name, even if it's unsafe .replace(/\$\{Property.raw\}/g, capitalize(name)) .replace(/\$\{property\}/g, safePropName(name))