title: Regex won't match words as expected
body: <p>I am trying to use <a href="http://xregexp.com/" rel="nofollow">XRegExp</a> to test if a string is a valid word according to these criteria:</p>
  
  <ul>
  <li>The string begins with one or more Unicode letters, followed by</li>
  <li>an apostrophe (<code>'</code>) followed by one or more Unicode letters, repeated 0 or more times.</li>
  <li>The string ends immediately after the matched pattern.</li>
  </ul>
  
  <p>That is, it will match these terms</p>
  
  <blockquote>
    <p>Hello can't Alah'u'u'v'oo O'reilly</p>
  </blockquote>
  
  <p>but not these</p>
  
  <blockquote>
    <p>eatin' 'sup 'til</p>
  </blockquote>
  
  <p>I am trying this pattern,</p>
  
  <pre><code>^(\\p{L})+('(\\p{L})+)*$
  </code></pre>
  
  <p>but it won't match any words that contain apostrophes. What am I doing wrong?</p>
  
  <p>EDIT: The code using the regex</p>
  
  <pre><code>var separateWords = function(text) {
      var word = XRegExp("(\\p{L})+('(\\p{L})+)*$");
      var splits = [];
      for (var i = 0; i &lt; text.length; i++) {
          var item = text[i];
          while (i + 1 &lt; text.length &amp;&amp; word.test(item + text[i + 1])) {
              item += text[i + 1];
              i++;
          }
          splits.push(item);
      }
      return splits;
  };
  </code></pre>