<table><tr><td style="">dfaure requested changes to this revision.<br />dfaure added a comment.<br />This revision now requires changes to proceed.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D26435">View Revision</a></tr></table><br /><div><div><blockquote style="border-left: 3px solid #8C98B8;
          color: #6B748C;
          font-style: italic;
          margin: 4px 0 12px 0;
          padding: 8px 12px;
          background-color: #F8F9FC;">
<div style="font-style: normal;
          padding-bottom: 4px;">In <a href="https://phabricator.kde.org/D26435#587956" style="background-color: #e7e7e7;
          border-color: #e7e7e7;
          border-radius: 3px;
          padding: 0 4px;
          font-weight: bold;
          color: black;text-decoration: none;">D26435#587956</a>, <a href="https://phabricator.kde.org/p/ahmadsamir/" style="
              border-color: #f1f7ff;
              color: #19558d;
              background-color: #f1f7ff;
                border: 1px solid transparent;
                border-radius: 3px;
                font-weight: bold;
                padding: 0 4px;">@ahmadsamir</a> wrote:</div>
<div style="margin: 0;
          padding: 0;
          border: 0;
          color: rgb(107, 116, 140);"><p>I look for usage of tagRegExp() with lxr.kde.org and couldn't find any.</p></div>
</blockquote>

<p>A file-static function is not exported outside that cpp file, so that's quite expected.</p></div></div><br /><div><strong>INLINE COMMENTS</strong><div><div style="margin: 6px 0 12px 0;"><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D26435#inline-148845">View Inline</a><span style="color: #4b4d51; font-weight: bold;">loaderutil.cpp:69</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; ">            <span class="n">QString</span> <span class="n">host</span> <span style="color: #aa2211">=</span> <span class="n">url</span><span class="p">.</span><span class="n">host</span><span class="p">();</span>
</div><div style="padding: 0 8px; margin: 0 4px; ">            <span class="n">rx</span><span class="p">.</span><span class="n">setPattern</span><span class="p">(</span><span class="n">QStringLiteral</span><span class="p">(</span><span style="color: #766510">"(?:<A )[^H]*(?)[^=]*=[^A-Z0-9-_~,./]*([^'</span><span style="color: #bb6622">\"</span><span style="color: #766510">></span><span style="color: #bb6622">\\</span><span style="color: #766510">s]*)"</span><span class="p">));</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(251, 175, 175, .7);">            <span class="bright"></span><span style="color: #aa4000"><span class="bright">while</span></span><span class="bright"> </span><span class="p"><span class="bright">(</span></span><span class="bright"></span><span class="n"><span class="bright">pos</span></span><span class="bright"> </span><span style="color: #aa2211"><span class="bright">>=</span></span><span class="bright"> </span><span style="color: #601200"><span class="bright">0</span></span><span class="bright"></span><span class="p"><span class="bright">)</span></span><span class="bright"> </span><span class="p"><span class="bright">{</span></span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);">            <span class="bright"></span><span class="n"><span class="bright">QRegularExpressionMatchIterator</span></span><span class="bright"> </span><span class="n"><span class="bright">iter</span></span><span class="bright"> </span><span style="color: #aa2211"><span class="bright">=</span></span><span class="bright"> </span><span class="n"><span class="bright">rx</span></span><span class="bright"></span><span class="p"><span class="bright">.</span></span><span class="bright"></span><span class="n"><span class="bright">globalMatch</span></span><span class="bright"></span><span class="p"><span class="bright">(</span></span><span class="bright"></span><span class="n"><span class="bright">str</span></span><span class="bright"></span><span class="p"><span class="bright">);</span></span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">Indeed that <tt style="background: #ebebeb; font-size: 13px;">(?)</tt> looks invalid. kregexpeditor says so, at least.</p>

<p style="padding: 0; margin: 8px;"><a href="https://phabricator.kde.org/p/mlaurent/" style="
              border-color: #f1f7ff;
              color: #19558d;
              background-color: #f1f7ff;
                border: 1px solid transparent;
                border-radius: 3px;
                font-weight: bold;
                padding: 0 4px;">@mlaurent</a> in commit <a href="https://phabricator.kde.org/R96:dda15b0aaddec01e31f862ba486a4e2876ab8eb8" style="background-color: #e7e7e7;
          border-color: #e7e7e7;
          border-radius: 3px;
          padding: 0 4px;
          font-weight: bold;
          color: black;text-decoration: none;">dda15b0aaddec01</a> you moved code around, but you also replaced <tt style="background: #ebebeb; font-size: 13px;">(?:HREF)</tt> with <tt style="background: #ebebeb; font-size: 13px;">(?)</tt>, while the rest of this regexp didn't change. Any reason for that?</p>

<p style="padding: 0; margin: 8px;">I think that either HREF should be added back, or <tt style="background: #ebebeb; font-size: 13px;">(?)</tt> should be removed.</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D26435#inline-148844">View Inline</a><span style="color: #4b4d51; font-weight: bold;">tools.cpp:159</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; ">    <span style="color: #74777d">//TODO: preserve some formatting, such as line breaks</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(251, 175, 175, .7);">    <span class="n">str</span><span class="p">.</span><span class="n">remove</span><span class="p">(</span><span class="n">QReg<span class="bright">Exp</span></span><span class="p">(</span><span class="n">QStringLiteral</span><span class="p">(</span><span style="color: #766510">"<[^>]*>"</span><span class="p">)));</span> <span style="color: #74777d">// remove tags</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);">    <span class="n">str</span><span class="p">.</span><span class="n">remove</span><span class="p">(</span><span class="n">QReg<span class="bright">ularExpression</span></span><span class="p">(</span><span class="n">QStringLiteral</span><span class="p">(</span><span style="color: #766510">"<[^>]*<span class="bright">?</span>>"</span><span class="p">)));</span> <span style="color: #74777d">// remove tags</span>
</div><div style="padding: 0 8px; margin: 0 4px; ">    <span class="n">str</span> <span style="color: #aa2211">=</span> <span class="n">resolveEntities</span><span class="p">(</span><span class="n">str</span><span class="p">);</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">Any reason for the added ? (for non-greedy-match)? I can't think of a case where it would make a difference, here.</p></div></div></div></div></div><br /><div><strong>REPOSITORY</strong><div><div>R96 PIM: Syndication Support</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D26435">https://phabricator.kde.org/D26435</a></div></div><br /><div><strong>To: </strong>ahmadsamir, dfaure, mlaurent<br /><strong>Cc: </strong>kde-pim, fbampaloukas, dcaliste, dvasin, rodsevich, winterz, vkrause, mlaurent, knauss, dvratil<br /></div>