<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/101754/">http://git.reviewboard.kde.org/r/101754/</a>
     </td>
    </tr>
   </table>
   <br />





<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
 <p style="margin-top: 0;">On June 25th, 2011, 9:19 a.m., <b>Milian Wolff</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Wait a sec, shouldn't you create an AliasDeclaration in that case (instead of actually importing the declaration from some other topcontext)? I mean the "using" directive in Cpp is more or less the same, and it works there, no? Why does that not work for you?</pre>
 </blockquote>




 <p>On June 25th, 2011, 10:10 a.m., <b>Sven Brauch</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
  <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 do create an AliasDeclaration, but the aliasedDeclaration() of that declaration might be in another top-context which has not necessarily anything to do with the one the AliasDeclaration is created in. Thus, as soon as the every-200-second cleanup is run, the topContext the aliasedDeclaration() is from may be cleaned, leaving me with a "(lost alias foo)" thingy in the original file. Isn't this the correct approach to solve that issue?

Bye,
Sven</pre>
 </blockquote>





 <p>On June 26th, 2011, 12:11 p.m., <b>David Nolden</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Ah, actually, you shouldn't even need to import the top-context for the aliasDeclaration to properly survive the cleanup. IndexedDeclaration is (should be) persistent among cleanups and unloading/loading. So you need to find out why this isn't the case.</pre>
 </blockquote>








</blockquote>

<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Oh, okay, so you'd say the whole approach is unnecessary, as it should work anyways? That's interesting, I'll try to investiage that. Thanks!</pre>
<br />








<p>- Sven</p>


<br />
<p>On June 25th, 2011, 12:40 a.m., Sven Brauch 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 KDevelop.</div>
<div>By Sven Brauch.</div>


<p style="color: grey;"><i>Updated June 25, 2011, 12:40 a.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;">This adds two small functions to the API which make it possible to manually add contexts to a topContexts importer map. Python language support makes use of this in the following case:

When importing a single declaration from a given top-context -- like required for the following: "from x import foo", which imports the declaration "foo" from the module "x" -- the context a declaration was taken from needs to be tracked, so it will not be auto-cleaned (making the importing context lose alias declarations). Using a function like addImportedParentContext() would do this automatically, but for obvious reasons those functions do not work in this case (because only a single declaration should be imported, not a whole context).
</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;">Seems to work in my case, and should not break anything as it just adds two small functions, not touching existing functionality.</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>language/duchain/topducontext.h <span style="color: grey">(6198a8f)</span></li>

 <li>language/duchain/topducontext.cpp <span style="color: grey">(402bd34)</span></li>

</ul>

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




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








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