Question about filter/source/msfilter/msdffimp.cxx
Lubos Lunak
l.lunak at suse.cz
Mon May 28 05:14:17 PDT 2012
On Monday 28 of May 2012, julien2412 wrote:
> Hello,
>
> I'm trying to understand why cppcheck (git updated today) hangs on the file
> liboroot/filter/source/msfilter/msdffimp.cxx
>
> I tried to find where was the problem and found that it worked if I
> commented just the following curly parenthesis (no need to comment the
> block inside)
> { (line 7294)
> } (line 7354)
>
> More bizarre is if I create a file with just the whole function
> SdrOle2Obj* SvxMSDffManager::CreateSdrOLEFromStorage (defined from line
> 7268) and without commenting these curly parenthesis, cppcheck worked !
>
> Before I create a tracker for cppcheck, I'd like to know at what
> corrrespond these curly parenthesis.
> I found nothing about this kind of construct in C++ however I know it's ok
> since it compiles ok.
It's simply a compound statement (i.e. block), just like any other. The only
difference is that this one is not attached to anything but it's standalone.
Its purpose seems to be to limit the scope for the xObjStg variable.
And yes, it should be a cppcheck bug.
--
Lubos Lunak
l.lunak at suse.cz
More information about the LibreOffice
mailing list