bug#40780: guile 3.0.2: Prevent warning using libguile with -Wpedantic (redefinition)

Hannes Müller <[email protected]>
Newsgroups gmane.lisp.guile.bugs
Message-ID <[email protected]>
Dear Maintainer,

2 warnings as shown below for libguile 3.0.2 (i.e. usage of libguile in
external C code) with gcc 9.3.0 and option -Wpedantic are indicated. In
contrast I get no warnings for libguile 2.2.7 with the same compiler
options. Therefore, please fix this easy to circumvent warning. 

Best regards
Hannes

In file included from /usr/include/guile/3.0/libguile/numbers.h:29,
                 from /usr/include/guile/3.0/libguile/array-
handle.h:27,
                 from /usr/include/guile/3.0/libguile.h:35,
                 from read_cfg.c:7:
/usr/include/guile/3.0/libguile/print.h:79:3: warning: redefinition of
typedef 'scm_print_state' [-Wpedantic]
   79 | } scm_print_state;
      |   ^~~~~~~~~~~~~~~
In file included from /usr/include/guile/3.0/libguile.h:33,
                 from read_cfg.c:7:
/usr/include/guile/3.0/libguile/scm.h:824:32: note: previous
declaration of 'scm_print_state' was here
  824 | typedef struct scm_print_state scm_print_state;
      |                                ^~~~~~~~~~~~~~~


In file included from /usr/include/guile/3.0/libguile/threads.h:27,
                 from /usr/include/guile/3.0/libguile/async.h:25,
                 from /usr/include/guile/3.0/libguile.h:38,
                 from read_cfg.c:7:
/usr/include/guile/3.0/libguile/dynstack.h:37:3: warning: redefinition
of typedef 'scm_t_dynstack' [-Wpedantic]
   37 | } scm_t_dynstack;
      |   ^~~~~~~~~~~~~~
In file included from /usr/include/guile/3.0/libguile.h:33,
                 from read_cfg.c:7:
/usr/include/guile/3.0/libguile/scm.h:825:29: note: previous
declaration of 'scm_t_dynstack' was here
  825 | typedef struct scm_dynstack scm_t_dynstack;
      |                             ^~~~~~~~~~~~~~
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.