diff options
author | Konstantin Käfer <mail@kkaefer.com> | 2014-10-30 15:06:18 -0400 |
---|---|---|
committer | Konstantin Käfer <mail@kkaefer.com> | 2014-10-30 15:06:18 -0400 |
commit | b6dea0d8de4ec823513b7f49d2b74fc97a661c28 (patch) | |
tree | 902a96ab8cb83c9a0f1790359c427887c4943c29 /include | |
parent | 242993b43a27e6f013e622bb4f268c4fdf436ac7 (diff) | |
download | qtlocation-mapboxgl-b6dea0d8de4ec823513b7f49d2b74fc97a661c28.tar.gz |
also allow underscores in token names
Diffstat (limited to 'include')
-rw-r--r-- | include/mbgl/util/token.hpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/mbgl/util/token.hpp b/include/mbgl/util/token.hpp index 0f045f434a..64192a99f9 100644 --- a/include/mbgl/util/token.hpp +++ b/include/mbgl/util/token.hpp @@ -22,7 +22,7 @@ std::string replaceTokens(const std::string &source, const Lookup &lookup) { result.append(pos, brace); pos = brace; if (pos != end) { - for (brace++; brace != end && std::isalnum(*brace); brace++); + for (brace++; brace != end && (std::isalnum(*brace) || *brace == '_'); brace++); if (brace != end && *brace == '}') { result.append(lookup({ pos + 1, brace })); pos = brace + 1; |