<div dir="ltr">It just comes to my mind that you could make StringSwitch case-insensitive instead of adding case-insensitive versions of StartsWith, Case and Cases. It'd probably be something like<div><br></div><div>  auto Ret = StringSwtich<T>(Str, /*CaseInsensitive=*/true)</div><div>      .Case("foo", bar) //  "foo" is compared in the insensitive manner</div><div>      ...</div><div><br></div><div>With this, you don't need to double the number of member functions.</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Oct 3, 2016 at 1:15 PM, Zachary Turner <span dir="ltr"><<a href="mailto:zturner@google.com" target="_blank">zturner@google.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">zturner updated this revision to Diff 73327.<br>
zturner added a comment.<br>
<br>
Unit tests for the case-sensitive versions were removed and submitted separately.  The `Optional` variant of the function is removed and will be submitted later.  This patch only contains case-insensitive versions of the functions with associated unit tests.<br>
<br>
<br>
<a href="https://reviews.llvm.org/D24686" rel="noreferrer" target="_blank">https://reviews.llvm.org/<wbr>D24686</a><br>
<br>
Files:<br>
  include/llvm/ADT/StringSwitch.<wbr>h<br>
  unittests/ADT/<wbr>StringSwitchTest.cpp<br>
<br>
</blockquote></div><br></div>