From 333e4c330ad0ead8bccb2789e4c04c144f7f97c1 Mon Sep 17 00:00:00 2001 From: Boris Zbarsky Date: Thu, 21 Sep 2023 08:51:28 -0400 Subject: [PATCH] Output MTR_AVAILABLE, not API_AVAILABLE for Darwin codegen. (#1146) This lets us control exactly what things expand to via our defines header. --- .../matter/darwin/Framework/CHIP/templates/helper.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src-electron/generator/matter/darwin/Framework/CHIP/templates/helper.js b/src-electron/generator/matter/darwin/Framework/CHIP/templates/helper.js index 68c1a943b4..edb02a4632 100644 --- a/src-electron/generator/matter/darwin/Framework/CHIP/templates/helper.js +++ b/src-electron/generator/matter/darwin/Framework/CHIP/templates/helper.js @@ -704,7 +704,7 @@ async function availability(clusterName, options) { let availabilityStrings = Object.entries(introducedVersions).map( ([os, version]) => `${os}(${version})` ); - return `API_AVAILABLE(${availabilityStrings.join(', ')})`; + return `MTR_AVAILABLE(${availabilityStrings.join(', ')})`; } if (!options.hash.deprecationMessage) { @@ -719,7 +719,7 @@ async function availability(clusterName, options) { let availabilityStrings = Object.entries(introducedVersions).map( ([os, version]) => `${os}(${version})` ); - return `API_AVAILABLE(${availabilityStrings.join( + return `MTR_AVAILABLE(${availabilityStrings.join( ', ' )})\nMTR_NEWLY_DEPRECATED("${options.hash.deprecationMessage}")`; }