Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [Dltk-dev] SourceModuleInfoCache

Thanks!

PS: Alex, I appologize for calling you 'apanchenk', I couldn't guess
your real name from CVS commit :)

On Mon, Jun 16, 2008 at 3:31 PM, Andrei Sobolev
<andrei.sobolev@xxxxxxxxx> wrote:
> Hi Michael,
>
> Fix we provided is required to remove unnecessary cache clear after parsing
> of resource with FINE_GRAINED flag.
> But Alex missed removing of resources. Now it is fixed in HEAD.
>
> Thanks
>>
>> Hi,
>>
>> I have a question regarding the fix 'apanchenk' has produced at
>> 11/06/08 10:57 in SourceModuleInfoCache:
>>
>> There's a condition that was added before removal of ISourceModule from
>> cache:
>>
>> if (isContentChanged(delta) || isWorkingCopy(delta)) {
>>    SourceModuleInfoCache.this.remove((ISourceModule) element);
>> }
>>
>> Is this was done intentionally? Since I have the situation now when
>> all our Unit Tests fail...
>> This is because we are creating and removing a temporary file between
>> tests in such a manner:
>>
>> @After
>> public void cleanTestFile() { // executes after each test
>>   if (testFile != null) {
>>      testFile.delete(true, null);
>>      testFile = null;
>>   }
>> }
>>
>> public void createFile(String data) { // executes by each test
>>   testFile = testProject.getFile("test.php");
>>   testFile.create(new ByteArrayInputStream(data.getBytes()), true, null);
>>   project.refreshLocal(IResource.DEPTH_INFINITE, null);
>>   project.build(IncrementalProjectBuilder.FULL_BUILD,
>> DLTKCore.BUILDER_ID, null, null);
>> }
>>
>> The content is changed, but the ISourceModule cache is not updated.
>>
>> Please advice.
>>
>> Thanks!
>>
>>
>
> _______________________________________________
> dltk-dev mailing list
> dltk-dev@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/dltk-dev
>



-- 
Michael


Back to the top