bug-bison
[Top][All Lists]
Advanced

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

Re: MacOS CW Pro 5 compile of Bison-1.28


From: Akim Demaille
Subject: Re: MacOS CW Pro 5 compile of Bison-1.28
Date: 02 Oct 2000 11:16:23 +0200
User-agent: Gnus/5.0807 (Gnus v5.8.7) XEmacs/21.1 (Channel Islands)

| -- It seems that file "bison.simple" (or "bison.s1" as it is called in the
| distribution) uses malloc(), free() without including the ISO C header
| <stdlib.h>.

Thanks for reporting this, we will investigate.

| -- Several files had included <config.h> instead of the correct "config.h".
| 
| -- mktemp() is not ISO C, so I substituted tmpnam(). Then one has to open
| each new file before calling tmpnam() again, because ISO C only guarantees
| name conflicts against existing files.
| 
| -- The temporary files were not deleted after the run of Bison -- but
| perhaps this is a feature, not a bug.

Precisely because you no longer mktemp.  The handling of tmp files in
bison is very unsatisfactory and shall be revamped before the next
release (have a look at src/files.c: this is probably the most
horrible C source I ever read).  Thanks.

| -- _nl_explode_name() and perhaps at some other places, had some illegal
| implicit type conversions, like
|   (const char *) -> (const unsigned char *)
| In addition, names starting with underscore or having a double underscore
| are normally reserved for the implementation of the compiler (at least in
| C++).

Related to gettext, not Bison per se.

| -- When editing the config.hin file by hand, it says "define LABEL if ...",
| whereas the use in the code fails to use the label in the form
| "defined(LABEL)", instead only using it directly as "LABEL". (Perhaps you
| use autoconfig which defines them to 1, so this formal error has not been
| noticed because of that.)

Good call!  Related to Autoconf though, but it is well spotted.  Thanks!

| -- The labels GNULOCALEDIR, LOCALE_ALIAS_PATH were not defined (probably
| supplied by the makefile then).

Right.

| -- There were two main(), in main.c and ansi2knr.c. This is not a problem
| when using a makefile, but when using a project file, it becomes confusing.

ansi2knr is used to processed Bison sources, it is not part of bison.

        Akim



reply via email to

[Prev in Thread] Current Thread [Next in Thread]