[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: too many warnings from Bison CVS for Pike
From: |
Joel E. Denny |
Subject: |
Re: too many warnings from Bison CVS for Pike |
Date: |
Mon, 30 Jan 2006 17:31:14 -0500 (EST) |
On Mon, 30 Jan 2006, Hans Aberg wrote:
> It is Paul Eggert that is doing the C skeleton, and I doubt he does anything
> with C++ in mind.
It is his posts where I first saw the malloc issue addressed in bison.
> And a strict C++ compiler will complain when
> using names such as "malloc", as the C++ name is "std::malloc". Is your C++
> compiler old?
Using g++ 4.0.1 (with -Wall -pedantic) or Sun's CC 5.7, the following
compiles without warning:
#include <stdlib.h>
#include <stdio.h>
int main() {
int *p = (int*)malloc(3);
printf ("%d\n", *p);
return 0;
}
Perhaps you're thinking of <cstdlib> rather than <stdlib.h>?
Joel
- Re: too many warnings from Bison CVS for Pike, (continued)
- Re: too many warnings from Bison CVS for Pike, Joel E. Denny, 2006/01/29
- Re: too many warnings from Bison CVS for Pike, Hans Aberg, 2006/01/29
- Re: too many warnings from Bison CVS for Pike, Joel E. Denny, 2006/01/29
- Re: too many warnings from Bison CVS for Pike, Hans Aberg, 2006/01/29
- Re: too many warnings from Bison CVS for Pike, Joel E. Denny, 2006/01/29
- Re: too many warnings from Bison CVS for Pike, Hans Aberg, 2006/01/29
- Re: too many warnings from Bison CVS for Pike, Joel E. Denny, 2006/01/29
- Re: too many warnings from Bison CVS for Pike, Hans Aberg, 2006/01/30
- Re: too many warnings from Bison CVS for Pike, Joel E. Denny, 2006/01/30
- Re: too many warnings from Bison CVS for Pike, Hans Aberg, 2006/01/30
- Re: too many warnings from Bison CVS for Pike,
Joel E. Denny <=
- Re: too many warnings from Bison CVS for Pike, Hans Aberg, 2006/01/30
- Re: too many warnings from Bison CVS for Pike, Joel E. Denny, 2006/01/30
- Re: too many warnings from Bison CVS for Pike, Hans Aberg, 2006/01/31
- Re: too many warnings from Bison CVS for Pike, Paul Eggert, 2006/01/30