From 6b0a2b81ca2b4054a0598514535780d04b39db5b Mon Sep 17 00:00:00 2001 From: Zufu Liu Date: Fri, 1 May 2020 21:34:42 +1000 Subject: Backport: Make lambdas noexcept. Backport of changeset 8222:b11c7c0d7978. --- src/ViewStyle.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/ViewStyle.cxx') diff --git a/src/ViewStyle.cxx b/src/ViewStyle.cxx index 43b48544c..8be2bdf6a 100644 --- a/src/ViewStyle.cxx +++ b/src/ViewStyle.cxx @@ -309,10 +309,10 @@ void ViewStyle::Refresh(Surface &surface, int tabInChars) { } indicatorsDynamic = std::any_of(indicators.cbegin(), indicators.cend(), - [](const Indicator &indicator) { return indicator.IsDynamic(); }); + [](const Indicator &indicator) noexcept { return indicator.IsDynamic(); }); indicatorsSetFore = std::any_of(indicators.cbegin(), indicators.cend(), - [](const Indicator &indicator) { return indicator.OverridesTextFore(); }); + [](const Indicator &indicator) noexcept { return indicator.OverridesTextFore(); }); maxAscent = 1; maxDescent = 1; @@ -327,10 +327,10 @@ void ViewStyle::Refresh(Surface &surface, int tabInChars) { lineOverlap = lineHeight; someStylesProtected = std::any_of(styles.cbegin(), styles.cend(), - [](const Style &style) { return style.IsProtected(); }); + [](const Style &style) noexcept { return style.IsProtected(); }); someStylesForceCase = std::any_of(styles.cbegin(), styles.cend(), - [](const Style &style) { return style.caseForce != Style::caseMixed; }); + [](const Style &style) noexcept { return style.caseForce != Style::caseMixed; }); aveCharWidth = styles[STYLE_DEFAULT].aveCharWidth; spaceWidth = styles[STYLE_DEFAULT].spaceWidth; -- cgit v1.2.3