diff options
Diffstat (limited to 'crawl-ref/source/libutil.cc')
-rw-r--r-- | crawl-ref/source/libutil.cc | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/crawl-ref/source/libutil.cc b/crawl-ref/source/libutil.cc index 1be3303110..7d06e22c5f 100644 --- a/crawl-ref/source/libutil.cc +++ b/crawl-ref/source/libutil.cc @@ -158,6 +158,13 @@ std::string &uppercase(std::string &s) return (s); } +std::string upcase_first(std::string s) +{ + if (!s.empty()) + s[0] = toupper(s[0]); + return (s); +} + std::string &lowercase(std::string &s) { for (unsigned i = 0, sz = s.size(); i < sz; ++i) @@ -809,4 +816,3 @@ bool pattern_match(void *compiled_pattern, const char *text, int length) #endif mouse_mode mouse_control::ms_current_mode = MOUSE_MODE_NORMAL; - |