public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/13601] New: declaration of structure variable errno busts syntax parser
@ 2004-01-07 16:53 sah at softcardsystems dot com
  2004-01-07 17:36 ` [Bug c/13601] " bangerth at dealii dot org
  0 siblings, 1 reply; 2+ messages in thread
From: sah at softcardsystems dot com @ 2004-01-07 16:53 UTC (permalink / raw)
  To: gcc-bugs

[sah@roscoe tmp]$ cat hw.c
#include <stdio.h>
#include <errno.h>

typedef struct s {
        char *errno;
} S;

int
main(void)
{
        S s;

        s.errno = "hello world";
        printf("%s\n", s.errno);

        return 0;
}
[sah@roscoe tmp]$ gcc -v -save-temps hw.c
Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/3.2.2/specs
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man 
--infodir=/usr/share/info --enable-shared --enable-threads=posix 
--disable-checking --with-system-zlib --enable-__cxa_atexit 
--host=i386-redhat-linux
Thread model: posix
gcc version 3.2.2 20030222 (Red Hat Linux 3.2.2-5)
 /usr/lib/gcc-lib/i386-redhat-linux/3.2.2/cpp0 -lang-c -v -D__GNUC__=3 
-D__GNUC_MINOR__=2 -D__GNUC_PATCHLEVEL__=2 -D__GXX_ABI_VERSION=102 -D__ELF__ 
-Dunix -D__gnu_linux__ -Dlinux -D__ELF__ -D__unix__ -D__gnu_linux__ -D__linux__ 
-D__unix -D__linux -Asystem=posix -D__NO_INLINE__ -D__STDC_HOSTED__=1 -Acpu=i386 
-Amachine=i386 -Di386 -D__i386 -D__i386__ -D__tune_i386__ hw.c hw.i
GNU CPP version 3.2.2 20030222 (Red Hat Linux 3.2.2-5) (cpplib) (i386 Linux/ELF)
ignoring nonexistent directory "/usr/i386-redhat-linux/include"
#include "..." search starts here:
#include <...> search starts here:
 /usr/local/include
 /usr/lib/gcc-lib/i386-redhat-linux/3.2.2/include
 /usr/include
End of search list.
 /usr/lib/gcc-lib/i386-redhat-linux/3.2.2/cc1 -fpreprocessed hw.i -quiet 
-dumpbase hw.c -version -o hw.s
GNU CPP version 3.2.2 20030222 (Red Hat Linux 3.2.2-5) (cpplib) (i386 Linux/ELF)
GNU C version 3.2.2 20030222 (Red Hat Linux 3.2.2-5) (i386-redhat-linux)
        compiled by GNU C version 3.2.2 20030222 (Red Hat Linux 3.2.2-5).
hw.c:5: field `__errno_location' declared as a function
hw.c: In function `main':
hw.c:13: parse error before '(' token
hw.c:14: parse error before '(' token
[sah@roscoe tmp]$

Get hw.i from: http://www.softcardsystems.com/sah/hw.i

Cheers,

Sam

-- 
           Summary: declaration of structure variable errno busts syntax
                    parser
           Product: gcc
           Version: 3.2.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: sah at softcardsystems dot com
                CC: gcc-bugs at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13601


^ permalink raw reply	[flat|nested] 2+ messages in thread

* [Bug c/13601] declaration of structure variable errno busts syntax parser
  2004-01-07 16:53 [Bug c/13601] New: declaration of structure variable errno busts syntax parser sah at softcardsystems dot com
@ 2004-01-07 17:36 ` bangerth at dealii dot org
  0 siblings, 0 replies; 2+ messages in thread
From: bangerth at dealii dot org @ 2004-01-07 17:36 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From bangerth at dealii dot org  2004-01-07 17:36 -------
Duplicate of PR 13600. 

*** This bug has been marked as a duplicate of 13600 ***

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |DUPLICATE


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13601


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2004-01-07 17:36 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-01-07 16:53 [Bug c/13601] New: declaration of structure variable errno busts syntax parser sah at softcardsystems dot com
2004-01-07 17:36 ` [Bug c/13601] " bangerth at dealii dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).