[petsc-dev] Compiling C code with C compiler
Satish Balay
balay at mcs.anl.gov
Mon Apr 4 21:17:31 CDT 2011
On Mon, 4 Apr 2011, Lisandro Dalcin wrote:
> On 4 April 2011 22:48, Satish Balay <balay at mcs.anl.gov> wrote:
> > There is clang and clang++ - but still they insist on throwing this warning.
> >
> > When I invoke clang++ - I want c++. So I'm not sure whats so ambiguous
> > that they should throw this warning.
> >
> > And what does this depricate mean? That 'clang++ foo.c' will create C code?
> >
> > Then why have both clang and clang++?
> >
>
> $ file /usr/bin/clang++
> /usr/bin/clang++: symbolic link to `clang'
>
> They should use argv[0] to dispatch C/C++, but it seems this is not the case.
They do that - but use it to print the warning. [and goes ahead and generates c++ code]
>>>>>>
asterix:/home/balay/junk>clang sizeof.c
asterix:/home/balay/junk>clang++ sizeof.c
clang: warning: treating 'c' input as 'c++' when in C++ mode, this behavior is deprecated
asterix:/home/balay/junk>
<<<<<<
More information about the petsc-dev
mailing list