<html>
 <body>
  <div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
   <table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 solid;">
    <tr>
     <td>
      This is an automatically generated e-mail. To reply, visit:
      <a href="http://git.reviewboard.kde.org/r/104511/">http://git.reviewboard.kde.org/r/104511/</a>
     </td>
    </tr>
   </table>
   <br />








<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
 <p style="margin-top: 0;">On April 10th, 2012, 2:38 a.m., <b>Maks Orlovich</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
  



<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
 <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
    <a href="http://git.reviewboard.kde.org/r/104511/diff/1/?file=56157#file56157line301" style="color: black; font-weight: bold; text-decoration: underline;">kjs/function.cpp</a>
    <span style="font-weight: normal;">

     (Diff revision 1)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
   <td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">void Arguments::getOwnPropertyNames(ExecState* exec, PropertyNameArray& propertyNames, PropertyMap::PropertyMode mode)</pre></td>

  </tr>
 </tbody>




 
 



 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
    <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">301</font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span class="n">JSValue</span><span class="o">*</span> <span class="n">jsLength</span> <span class="o">=</span> <span class="n">getDirect</span><span class="p">(</span><span class="n">exec</span><span class="o">-></span><span class="n">propertyNames</span><span class="p">().</span><span class="n">length</span><span class="p">);</span></pre></td>
  </tr>

 </tbody>

</table>

  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">How should this react when the length property is altered?
</pre>
 </blockquote>





</blockquote>
<pre style="margin-left: 1em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">good question, I don't know, not explicitly covered as I can see. But I guess it would make sense that it shows 0 to length-1 parameters, if the they are all mapped.</pre>
<br />

<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
 <p style="margin-top: 0;">On April 10th, 2012, 2:38 a.m., <b>Maks Orlovich</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
  



<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
 <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
    <a href="http://git.reviewboard.kde.org/r/104511/diff/1/?file=56157#file56157line308" style="color: black; font-weight: bold; text-decoration: underline;">kjs/function.cpp</a>
    <span style="font-weight: normal;">

     (Diff revision 1)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
   <td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">void Arguments::getOwnPropertyNames(ExecState* exec, PropertyNameArray& propertyNames, PropertyMap::PropertyMode mode)</pre></td>

  </tr>
 </tbody>




 
 



 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
    <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">308</font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">        <span class="k">if</span> <span class="p">(</span><span class="n">indexToNameMap</span><span class="p">.</span><span class="n">isMapped</span><span class="p">(</span><span class="n">ident</span><span class="p">)</span> <span class="o">&&</span> <span class="n">_activationObject</span><span class="o">-></span><span class="n">getPropertyAttributes</span><span class="p">(</span><span class="n">indexToNameMap</span><span class="p">[</span><span class="n">ident</span><span class="p">],</span> <span class="n">attr</span><span class="p">))</span> <span class="p">{</span></pre></td>
  </tr>

 </tbody>

</table>

  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Why convert to ident when isMapped will convert back to number again? Just add  aversion that takes a number; similarly [] works on numbers already. (And perhaps fix up some of the sloppiness with signs there)</pre>
 </blockquote>





</blockquote>
<pre style="margin-left: 1em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Nononono!, I figured out that I have to be very careful with the number versions. The problem is the numbers have attributes too. If I overwrite it, it will only return the properties of the mapped object. In other places I need the properties for the numbers too. (defineOwnProperty for example)
So I must not add a number version.</pre>
<br />

<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
 <p style="margin-top: 0;">On April 10th, 2012, 2:38 a.m., <b>Maks Orlovich</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
  



<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
 <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
    <a href="http://git.reviewboard.kde.org/r/104511/diff/1/?file=56158#file56158line431" style="color: black; font-weight: bold; text-decoration: underline;">kjs/object.h</a>
    <span style="font-weight: normal;">

     (Diff revision 1)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="4"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">namespace KJS {</pre></td>

  </tr>
 </tbody>




 
 



 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
    <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">431</font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span class="c1">//KDE5: merge those two getOwnPropertyNames, with default mode PropertyMap::ExcludeDontEnumProperties</span></pre></td>
  </tr>

 </tbody>

</table>

  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">It's OK to make API changes here; just make sure you fix every call site. Frankly, past experience shows that overloaded virtual groups like this are a mistake and hard to get right (there have been bugs caused with the getters, for example).
</pre>
 </blockquote>





</blockquote>
<pre style="margin-left: 1em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Oh good :)
I would love to clean it, I was told that I should avoid API changes, but if you are ok with it, I will do it.</pre>
<br />

<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
 <p style="margin-top: 0;">On April 10th, 2012, 2:38 a.m., <b>Maks Orlovich</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
  



<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
 <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
    <a href="http://git.reviewboard.kde.org/r/104511/diff/1/?file=56159#file56159line496" style="color: black; font-weight: bold; text-decoration: underline;">kjs/object.cpp</a>
    <span style="font-weight: normal;">

     (Diff revision 1)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="4"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">bool JSObject::getPropertyAttributes(const Identifier& propertyName, unsigned& attributes) const</pre></td>

  </tr>
 </tbody>



 
 




 <tbody>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2">491</font></th>
    <td bgcolor="#fdfebc" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">        <span class="k">if</span> <span class="p">(</span><span class="n">e</span><span class="o">-></span><span class="n">s</span> <span class="o">&&</span> <span class="o">!</span><span class="p">(</span><span class="n">e</span><span class="o">-></span><span class="n">attr</span> <span class="o">&</span> <span class="n">DontEnum</span><span class="p">)<span class="hl">)</span></span></pre></td>
    <th bgcolor="#e9eaa8" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">496</font></th>
    <td bgcolor="#fdfebc" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">        <span class="k">if</span> <span class="p">(</span><span class="n">e</span><span class="o">-></span><span class="n">s</span> <span class="o">&&</span> <span class="p"><span class="hl">(</span></span><span class="o">!</span><span class="p">(</span><span class="n">e</span><span class="o">-></span><span class="n">attr</span> <span class="o">&</span> <span class="n">DontEnum</span><span class="p">)</span><span class="hl"> </span><span class="o"><span class="hl">||</span></span><span class="hl"> </span><span class="n"><span class="hl">mode</span></span><span class="hl"> </span><span class="o"><span class="hl">==</span></span><span class="hl"> </span><span class="n"><span class="hl">PropertyMap</span></span><span class="o"><span class="hl">::</span></span><span class="n"><span class="hl">IncludeDontEnumProperties</span></span><span class="p"><span class="hl">))</span></span></pre></td>
  </tr>

 </tbody>

</table>

  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">This might actually show up on some benchmarks. I bet you can speed this up by making an appropriate choice of value for PropertyMap::IncludeDontEnumProperties -- basically making it a mask on attr, but that may be a bit brittle maintenance wise</pre>
 </blockquote>





</blockquote>
<pre style="margin-left: 1em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">uhm really? for maintenance I would really say I am against it. And I doubt that it would really show up on some benchmarks... unless you are benchmarking huge objects/arrays with millions of properties</pre>
<br />

<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
 <p style="margin-top: 0;">On April 10th, 2012, 2:38 a.m., <b>Maks Orlovich</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
  



<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
 <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
    <a href="http://git.reviewboard.kde.org/r/104511/diff/1/?file=56160#file56160line241" style="color: black; font-weight: bold; text-decoration: underline;">kjs/object_object.cpp</a>
    <span style="font-weight: normal;">

     (Diff revision 1)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
   <td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">JSValue *ObjectObjectFuncImp::callAsFunction(ExecState* exec, JSObject*, const List& args)</pre></td>

  </tr>
 </tbody>




 
 



 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
    <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">241</font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">        <span class="k">return</span> <span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">]</span><span class="o">-></span><span class="n">getObject</span><span class="p">()</span><span class="o">-></span><span class="n">prototype</span><span class="p">();</span></pre></td>
  </tr>

 </tbody>

</table>

  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Faster: save return value of getObject() and check that for null. (Note that it matters here..)</pre>
 </blockquote>





</blockquote>
<pre style="margin-left: 1em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">done</pre>
<br />

<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
 <p style="margin-top: 0;">On April 10th, 2012, 2:38 a.m., <b>Maks Orlovich</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
  



<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
 <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
    <a href="http://git.reviewboard.kde.org/r/104511/diff/1/?file=56160#file56160line251" style="color: black; font-weight: bold; text-decoration: underline;">kjs/object_object.cpp</a>
    <span style="font-weight: normal;">

     (Diff revision 1)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
   <td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">JSValue *ObjectObjectFuncImp::callAsFunction(ExecState* exec, JSObject*, const List& args)</pre></td>

  </tr>
 </tbody>




 
 



 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
    <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">251</font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">        <span class="n">jso</span><span class="o">-></span><span class="n">getOwnPropertyNames</span><span class="p">(</span><span class="n">exec</span><span class="p">,</span> <span class="n">propertyNames</span><span class="p">,</span> <span class="n">PropertyMap</span><span class="o">::</span><span class="n">IncludeDontEnumProperties</span><span class="p">);</span></pre></td>
  </tr>

 </tbody>

</table>

  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">So this one shows the DontEnum ones? Joy. </pre>
 </blockquote>





</blockquote>
<pre style="margin-left: 1em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Yes that also includes the DontEnum ones. Is this just comment or is there something I overlook? (As this is an Issue that stops the "Ship it!")</pre>
<br />




<p>- Bernd</p>


<br />
<p>On April 8th, 2012, 9:14 p.m., Bernd Buschinski wrote:</p>






<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" style="background-image: url('http://git.reviewboard.kde.org/media/rb/images/review_request_box_top_bg.png'); background-position: left top; background-repeat: repeat-x; border: 1px black solid;">
 <tr>
  <td>

<div>Review request for kdelibs.</div>
<div>By Bernd Buschinski.</div>


<p style="color: grey;"><i>Updated April 8, 2012, 9:14 p.m.</i></p>






<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
 <table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
 <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">KJS: Implement Object.prototypeOf, Object.keys, Object.getOwnPropertyNames

NOTE: Array was left out on purpose, as currentl imeplementation does not save attributes (next patch will fix this)

keys&GetOwnPropertyNames requieres to change the JSObject::getOwnPropertyNames implementation,
for future use a enum is better than than a bool, maybe there will be more ways to include/exclude properties.

All changes for khtml/ecma/ are to silense the -Woverloaded-virtual warnings</pre>
  </td>
 </tr>
</table>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
 <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">ecma script & daily surfing</pre>
  </td>
 </tr>
</table>




<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">

 <li>khtml/ecma/kjs_css.h <span style="color: grey">(aba44b8)</span></li>

 <li>khtml/ecma/kjs_css.cpp <span style="color: grey">(e3e7417)</span></li>

 <li>khtml/ecma/kjs_dom.h <span style="color: grey">(d0433c3)</span></li>

 <li>khtml/ecma/kjs_dom.cpp <span style="color: grey">(5fff7e3)</span></li>

 <li>khtml/ecma/kjs_html.h <span style="color: grey">(0f3f544c)</span></li>

 <li>khtml/ecma/kjs_html.cpp <span style="color: grey">(e3da95c)</span></li>

 <li>khtml/ecma/kjs_scriptable.h <span style="color: grey">(af5343c)</span></li>

 <li>khtml/ecma/kjs_scriptable.cpp <span style="color: grey">(5d4ea68)</span></li>

 <li>kjs/JSVariableObject.h <span style="color: grey">(a8f01eb)</span></li>

 <li>kjs/JSVariableObject.cpp <span style="color: grey">(b00ef76)</span></li>

 <li>kjs/array_instance.h <span style="color: grey">(3f2b630)</span></li>

 <li>kjs/function.h <span style="color: grey">(3757fe8)</span></li>

 <li>kjs/function.cpp <span style="color: grey">(5f39ae6)</span></li>

 <li>kjs/object.h <span style="color: grey">(047c242)</span></li>

 <li>kjs/object.cpp <span style="color: grey">(c19122f)</span></li>

 <li>kjs/object_object.cpp <span style="color: grey">(986f03f)</span></li>

 <li>kjs/property_map.h <span style="color: grey">(6b127ff)</span></li>

 <li>kjs/property_map.cpp <span style="color: grey">(b2ff08e)</span></li>

 <li>kjs/string_object.h <span style="color: grey">(e890d52)</span></li>

 <li>kjs/string_object.cpp <span style="color: grey">(170e2f7)</span></li>

</ul>

<p><a href="http://git.reviewboard.kde.org/r/104511/diff/" style="margin-left: 3em;">View Diff</a></p>




  </td>
 </tr>
</table>








  </div>
 </body>
</html>