Use SAL_N_ELEMENTS

Change-Id: I643d839a2b1d8473c484c659793bd3344ace8859
This commit is contained in:
Eike Rathke 2017-10-25 12:11:29 +02:00
parent 425e06aa7f
commit 660df84c94

View file

@ -351,7 +351,7 @@ void LCInfoNode::generateCode (const OFileWriter &of) const
of.writeAsciiString("\tcountryDefaultName,\n");
of.writeAsciiString("\tVariant\n");
of.writeAsciiString("};\n\n");
of.writeFunction("getLCInfo_", "(sizeof(LCInfoArray)/sizeof(LCInfoArray[0]))", "LCInfoArray");
of.writeFunction("getLCInfo_", "SAL_N_ELEMENTS(LCInfoArray)", "LCInfoArray");
}
@ -574,7 +574,7 @@ void LCCTYPENode::generateCode (const OFileWriter &of) const
of.writeAsciiString("\tLongDateMonthSeparator,\n");
of.writeAsciiString("\tLongDateYearSeparator\n");
of.writeAsciiString("};\n\n");
of.writeFunction("getLocaleItem_", "(sizeof(LCType)/sizeof(LCType[0]))", "LCType");
of.writeFunction("getLocaleItem_", "SAL_N_ELEMENTS(LCType)", "LCType");
}