<html>
    <head>
      <base href="https://bugs.webkit.org/" />
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - Surrogates without valid trail assert in ComplexTextController"
   href="https://bugs.webkit.org/show_bug.cgi?id=151907">151907</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Surrogates without valid trail assert in ComplexTextController
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>WebKit
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>WebKit Nightly Build
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>Macintosh
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Mac OS X 10.11
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>Normal
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P2
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>Text
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>webkit-unassigned&#64;lists.webkit.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>benjamin&#64;webkit.org
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>mmaxfield&#64;apple.com
          </td>
        </tr></table>
      <p>
        <div>
        <pre>The test of <a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - [INTL] Implement String.prototype.toLocaleLowerCase in ECMA-402"
   href="show_bug.cgi?id=147608">https://bugs.webkit.org/show_bug.cgi?id=147608</a> hits an assertion in ComplexTextController for perfectly reasonable input. We should have a test specifically for this case.

The backtrace:

0   com.apple.JavaScriptCore          0x000000010d8a1d77 WTFCrash + 39
1   com.apple.WebCore                 0x00000001124128c4 WebCore::ComplexTextController::ComplexTextRun::ComplexTextRun(WebCore::Font const&amp;, unsigned short const*, unsigned int, unsigned long, bool) + 484 (ComplexTextControllerCoreText.mm:154)
2   com.apple.WebCore                 0x0000000112412d54 WebCore::ComplexTextController::ComplexTextRun::ComplexTextRun(WebCore::Font const&amp;, unsigned short const*, unsigned int, unsigned long, bool) + 68 (ComplexTextControllerCoreText.mm:173)
3   com.apple.WebCore                 0x00000001124155c8 WebCore::ComplexTextController::ComplexTextRun::create(WebCore::Font const&amp;, unsigned short const*, unsigned int, unsigned long, bool) + 120 (ComplexTextController.h:85)
4   com.apple.WebCore                 0x000000011241408b WebCore::ComplexTextController::collectComplexTextRunsForCharacters(unsigned short const*, unsigned int, unsigned int, WebCore::Font const*) + 4907 (ComplexTextControllerCoreText.mm:285)
5   com.apple.WebCore                 0x0000000112401eb8 WebCore::ComplexTextController::collectComplexTextRuns() + 1448 (ComplexTextController.cpp:366)
6   com.apple.WebCore                 0x00000001124017ff WebCore::ComplexTextController::ComplexTextController(WebCore::FontCascade const&amp;, WebCore::TextRun const&amp;, bool, WTF::HashSet&lt;WebCore::Font const*, WTF::PtrHash&lt;WebCore::Font const*&gt;, WTF::HashTraits&lt;WebCore::Font const*&gt; &gt;*, bool) + 671 (ComplexTextController.cpp:144)
7   com.apple.WebCore                 0x0000000112403a24 WebCore::ComplexTextController::ComplexTextController(WebCore::FontCascade const&amp;, WebCore::TextRun const&amp;, bool, WTF::HashSet&lt;WebCore::Font const*, WTF::PtrHash&lt;WebCore::Font const*&gt;, WTF::HashTraits&lt;WebCore::Font const*&gt; &gt;*, bool) + 84 (ComplexTextController.cpp:158)
8   com.apple.WebCore                 0x0000000112a0da1f WebCore::FontCascade::floatWidthForComplexText(WebCore::TextRun const&amp;, WTF::HashSet&lt;WebCore::Font const*, WTF::PtrHash&lt;WebCore::Font const*&gt;, WTF::HashTraits&lt;WebCore::Font const*&gt; &gt;*, WebCore::GlyphOverflow*) const + 111 (FontCascadeCocoa.mm:677)
9   com.apple.WebCore                 0x00000001129f90f8 WebCore::FontCascade::width(WebCore::TextRun const&amp;, WTF::HashSet&lt;WebCore::Font const*, WTF::PtrHash&lt;WebCore::Font const*&gt;, WTF::HashTraits&lt;WebCore::Font const*&gt; &gt;*, WebCore::GlyphOverflow*) const + 536 (FontCascade.cpp:372)
10  com.apple.WebCore                 0x0000000113e1ead5 WebCore::RenderText::widthFromCache(WebCore::FontCascade const&amp;, int, int, float, WTF::HashSet&lt;WebCore::Font const*, WTF::PtrHash&lt;WebCore::Font const*&gt;, WTF::HashTraits&lt;WebCore::Font const*&gt; &gt;*, WebCore::GlyphOverflow*, WebCore::RenderStyle const&amp;) const + 1237 (RenderText.cpp:502)
11  com.apple.WebCore                 0x0000000113e1be94 WebCore::RenderText::width(unsigned int, unsigned int, WebCore::FontCascade const&amp;, float, WTF::HashSet&lt;WebCore::Font const*, WTF::PtrHash&lt;WebCore::Font const*&gt;, WTF::HashTraits&lt;WebCore::Font const*&gt; &gt;*, WebCore::GlyphOverflow*) const + 628 (RenderText.cpp:1238)
12  com.apple.WebCore                 0x000000011379ca2f WebCore::textWidth(WebCore::RenderText&amp;, unsigned int, unsigned int, WebCore::FontCascade const&amp;, float, bool, bool, WTF::HashSet&lt;WebCore::Font const*, WTF::PtrHash&lt;WebCore::Font const*&gt;, WTF::HashTraits&lt;WebCore::Font const*&gt; &gt;&amp;, WebCore::TextLayout*) + 239 (BreakingContext.h:619)
13  com.apple.WebCore                 0x000000011379346f WebCore::BreakingContext::handleText(WTF::Vector&lt;WebCore::WordMeasurement, 64ul, WTF::CrashOnOverflow, 16ul&gt;&amp;, bool&amp;, unsigned int&amp;) + 5775 (BreakingContext.h:843)
14  com.apple.WebCore                 0x000000011378ebf1 WebCore::LineBreaker::nextLineBreak(WebCore::BidiResolverWithIsolate&lt;WebCore::InlineIterator, WebCore::BidiRun, WebCore::BidiIsolatedRun&gt;&amp;, WebCore::LineInfo&amp;, WebCore::LineLayoutState&amp;, WebCore::RenderTextInfo&amp;, WebCore::FloatingObject*, unsigned int, WTF::Vector&lt;WebCore::WordMeasurement, 64ul, WTF::CrashOnOverflow, 16ul&gt;&amp;) + 993 (LineBreaker.cpp:110)
15  com.apple.WebCore                 0x0000000113b71e85 WebCore::RenderBlockFlow::layoutRunsAndFloatsInRange(WebCore::LineLayoutState&amp;, WebCore::BidiResolverWithIsolate&lt;WebCore::InlineIterator, WebCore::BidiRun, WebCore::BidiIsolatedRun&gt;&amp;, WebCore::InlineIterator const&amp;, WebCore::BidiStatus const&amp;, unsigned int) + 1093 (RenderBlockLineLayout.cpp:1264)
16  com.apple.WebCore                 0x0000000113b709bb WebCore::RenderBlockFlow::layoutRunsAndFloats(WebCore::LineLayoutState&amp;, bool) + 1211 (RenderBlockLineLayout.cpp:1218)
17  com.apple.WebCore                 0x0000000113b7563a WebCore::RenderBlockFlow::layoutLineBoxes(bool, WebCore::LayoutUnit&amp;, WebCore::LayoutUnit&amp;) + 2010 (RenderBlockLineLayout.cpp:1647)
18  com.apple.WebCore                 0x0000000113b4da12 WebCore::RenderBlockFlow::layoutInlineChildren(bool, WebCore::LayoutUnit&amp;, WebCore::LayoutUnit&amp;) + 386 (RenderBlockFlow.cpp:652)
19  com.apple.WebCore                 0x0000000113b4ca6b WebCore::RenderBlockFlow::layoutBlock(bool, WebCore::LayoutUnit) + 1099 (RenderBlockFlow.cpp:483)</pre>
        </div>
      </p>
      <hr>
      <span>You are receiving this mail because:</span>
      
      <ul>
          <li>You are the assignee for the bug.</li>
      </ul>
    </body>
</html>