From 9cf92770827daf79860fb640caf3dc64a8e3d24e Mon Sep 17 00:00:00 2001 From: twanvl Date: Mon, 10 Jan 2011 19:39:16 +0000 Subject: [PATCH] (minor) git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@1610 0fc631ac-6414-0410-93d0-97cfa31319b6 --- src/util/regex.hpp | 4 ++-- src/util/rotation.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/util/regex.hpp b/src/util/regex.hpp index fcb48b62..e56cedbb 100644 --- a/src/util/regex.hpp +++ b/src/util/regex.hpp @@ -61,8 +61,8 @@ inline bool matches(const String& str) const { return regex_search(str.begin(), str.end(), regex); } - inline bool matches(Results& results, const String& str) const { - return matches(results, str.begin(), str.end()); + inline bool matches(Results& results, const String& str, size_t start = 0) const { + return matches(results, str.begin() + start, str.end()); } inline bool matches(Results& results, const String::const_iterator& begin, const String::const_iterator& end) const { return regex_search(begin, end, results, regex); diff --git a/src/util/rotation.cpp b/src/util/rotation.cpp index 476c7c5d..c70881ae 100644 --- a/src/util/rotation.cpp +++ b/src/util/rotation.cpp @@ -75,9 +75,9 @@ RealSize Rotation::trSizeToBB(const RealSize& size) const { } RealRect Rotation::trRectToBB(const RealRect& r) const { + const bool special_case_optimization = false; double x = r.x * zoomX, y = r.y * zoomY; double w = r.width * zoomX, h = r.height * zoomY; - const bool special_case_optimization = false; if (special_case_optimization && is_rad0(angle)) { return RealRect(origin.x + x, origin.y + y, w, h); } else if (special_case_optimization && is_rad180(angle)) {