[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [creduce-dev] unifdef



I'm running creduce under Windows but this should work same in the shell:

g++ -std=c++11 -fsyntax-only incremental_components.cpp -w && clang++ -std=c++11 -fsyntax-only incremental_components.cpp -w 2>&1 | grep "error: no matching function for call to 'get'" 

BTW, I last ran this with previous creduce some months ago, maybe some of the new features will make the reduce go better. I'm trying this now with current creduce, pass_includes immediately deletes 3/8 includes. This is typical.


2015-11-01 10:18 GMT+02:00 John Regehr <regehr@cs.utah.edu>:
Yes, -werror typically makes reduction much harder!

Can you send me your interestingness test?

John


On 11/1/15 7:23 AM, Yaron Keren wrote:
Hi John,

Your guess is right, I am interested in a reduced example outlining the
different behaviour of template instantiation/specialization in clang vs
gcc leading to the error. So yes the test should look for the specific
clang error message "error: no matching function for call to 'get'"
while gcc is OK with the code. Sorry for not writing this.

I'm not sure about the -w, though. The original code compiles without
any warning on gcc so ideally this behaviour should be kept in the
reduced example. It may make reducing much harder, though, so we could
probably start with -w and see how it goes.

Yaron



2015-11-01 1:19 GMT+02:00 John Regehr <regehr@cs.utah.edu
<mailto:regehr@cs.utah.edu>>:

    Well, I probably did something wrong but using this interestingness
    test:

    g++ -c -std=c++11 -fsyntax-only incremental_components.cpp -w &&
    ! clang++ -c -std=c++11 -fsyntax-only incremental_components.cpp -w

    C-Reduce rather quickly came up with this:

    constexpr int x0() { return __builtin_tanhl(0); }

    Do you have a better interestingness test for me?  Should I be
    looking for a specific error message from clang++ I guess?

    John