aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/CaseConvert.cxx
diff options
context:
space:
mode:
authormitchell <unknown>2020-01-05 21:22:02 -0500
committermitchell <unknown>2020-01-05 21:22:02 -0500
commit60e87889d6438e386acf58c3967fb874af9aae82 (patch)
tree9c5c2660c59aff04ddedea19fa03fd271f8bba5c /src/CaseConvert.cxx
parentdbb7374c185718655dd77c294eb281e8b93c538e (diff)
downloadscintilla-mirror-60e87889d6438e386acf58c3967fb874af9aae82.tar.gz
Added Sci::make_unique() and Sci::size() for better compatibility with the default branch.
std::make_unique() is c++14 and std::size() is c++17.
Diffstat (limited to 'src/CaseConvert.cxx')
-rw-r--r--src/CaseConvert.cxx6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/CaseConvert.cxx b/src/CaseConvert.cxx
index ed94a67f1..dd8a25aa1 100644
--- a/src/CaseConvert.cxx
+++ b/src/CaseConvert.cxx
@@ -19,6 +19,8 @@
#include "CaseConvert.h"
#include "UniConversion.h"
+#include "Compat.h"
+
using namespace Scintilla;
namespace {
@@ -692,7 +694,7 @@ void AddSymmetric(enum CaseConversion conversion, int lower,int upper) {
void SetupConversions(enum CaseConversion conversion) {
// First initialize for the symmetric ranges
- for (size_t i=0; i<ELEMENTS(symmetricCaseConversionRanges);) {
+ for (size_t i=0; i<Sci::size(symmetricCaseConversionRanges);) {
const int lower = symmetricCaseConversionRanges[i++];
const int upper = symmetricCaseConversionRanges[i++];
const int length = symmetricCaseConversionRanges[i++];
@@ -702,7 +704,7 @@ void SetupConversions(enum CaseConversion conversion) {
}
}
// Add the symmetric singletons
- for (size_t i=0; i<ELEMENTS(symmetricCaseConversions);) {
+ for (size_t i=0; i<Sci::size(symmetricCaseConversions);) {
const int lower = symmetricCaseConversions[i++];
const int upper = symmetricCaseConversions[i++];
AddSymmetric(conversion, lower, upper);