<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="https://git.reviewboard.kde.org/r/118215/">https://git.reviewboard.kde.org/r/118215/</a>
</td>
</tr>
</table>
<br />
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">I'm not sure about this. It looks like it would break when you try to re-open the declarations on subsequent parser passes. If you like you can submit it (since it's so simple), and if we run into issues with completion later we'll know why it is. ;)</pre>
<br />
<p>- Sven Brauch</p>
<br />
<p>On May 20th, 2014, 11:33 a.m. UTC, Denis Steckelmacher wrote:</p>
<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" style="background-image: url('https://git.reviewboard.kde.org/static/rb/images/review_request_box_top_bg.ab6f3b1072c9.png'); background-position: left top; background-repeat: repeat-x; border: 1px black solid;">
<tr>
<td>
<div>Review request for KDevelop.</div>
<div>By Denis Steckelmacher.</div>
<p style="color: grey;"><i>Updated May 20, 2014, 11:33 a.m.</i></p>
<div style="margin-top: 1.5em;">
<b style="color: #575012; font-size: 10pt;">Repository: </b>
kdev-qmljs
</div>
<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;">In QML, component instances (identified by an "id" property) are globally visible and can even be used before they are declared. This patch ensures that QML component instances are declared in the top-level context of their document, but does not address the problem of components used before they are declared.
QML components themselves must also be declared in the top-level context of their module. For instance, a Rectangle component declared like this:
Module {
Component {
name: "Rectangle"
}
}
Must be declared as "Rectangle", and not "Module::Rectangle" as is the case without this patch. Having Rectangle declared in the top-level context will allow import statements to work as expected (if you import a module, you expect Rectangle to be available, not Module.Rectangle).</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;">Two C++ unit tests have been changed, because every QML component instance is now declared in the top-level context (and not only the top-level component). All the other unit tests pass unchanged.</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>duchain/declarationbuilder.cpp <span style="color: grey">(a0a34af)</span></li>
<li>duchain/tests/testdeclarations.cpp <span style="color: grey">(476c673)</span></li>
</ul>
<p><a href="https://git.reviewboard.kde.org/r/118215/diff/" style="margin-left: 3em;">View Diff</a></p>
</td>
</tr>
</table>
</div>
</body>
</html>