Hi,

We are happy using ccache with clang but I just discovered today that ccache hides documentation warnings!

I am using clang 3.7.1, ccache 3.2.4.

/opt/clang-3.7/bin/clang++ --version
clang version 3.7.1 (tags/RELEASE_371/final)
Target: x86_64-unknown-linux-gnu
Thread model: posix

ccache --version
ccache version 3.2.4


Here is a small function file (foo.cc) with wrong doxygen documentation.

If I compile directly with clang++ I have 3 warnings:

===================================================================
/opt/clang-3.7/bin/clang++ -Weverything -c foo.cc
foo.cc:7:5: warning: '\return' command used in a comment that is attached to a function returning void [-Wdocumentation]
 * \return true there is no return value... 2nd warning
   ~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
foo.cc:5:11: warning: parameter 'pThis' not found in the function declaration [-Wdocumentation]
 * \param pThis there is no such param... 1st warning...
          ^~~~~
foo.cc:10:6: warning: no previous prototype for function 'foo' [-Wmissing-prototypes]
void foo(){}
     ^
===================================================================

ok, so far so good...


But if I compile it with ccache, the 2 warnings about documentation are disappearing:

ccache /opt/clang-3.7/bin/clang++ -Weverything -c foo.cc
foo.cc:10:6: warning: no previous prototype for function 'foo' [-Wmissing-prototypes]
void foo(){}

My CC* environment variables:

CCACHE_SLOPPINESS=include_file_mtime
CCACHE_DIR=/home/ccache/cmpbib/ccache
CCACHE_CPP2=yes
CCACHE_HARDLINK=1
CCACHE_HASHDIR=

How can I retrieve the documentation warnings with ccache? Do I do something wrong?

Thanks,

Eric

/*!
 *****************************************************************************
 * A simple example of wring doxygen documentation that clang must warn about..
 *
 * \param pThis there is no such param... 1st warning...
 *
 * \return true there is no return value... 2nd warning
 *
 *****************************************************************************/
void foo(){}

_______________________________________________
ccache mailing list
ccache@lists.samba.org
https://lists.samba.org/mailman/listinfo/ccache

Reply via email to