Branch: Tag:

2001-07-01

2001-07-01 21:34:51 by Martin Stjernholm <mast@lysator.liu.se>

Avoid the missing initializer warnings if the compiler allows us to
initialize unions.

Rev: src/acconfig.h:1.88
Rev: src/array.c:1.115
Rev: src/bignum.c:1.22
Rev: src/configure.in:1.530
Rev: src/encode.c:1.102
Rev: src/error.c:1.73
Rev: src/mapping.c:1.128
Rev: src/svalue.c:1.109

1: - AC_REVISION("$Id: configure.in,v 1.529 2001/06/29 23:26:48 hubbe Exp $") + AC_REVISION("$Id: configure.in,v 1.530 2001/07/01 21:34:50 mast Exp $")   AC_INIT(interpret.c)   AC_CONFIG_HEADER(machine.h)   
4964:      #######################################################################    + AC_MSG_CHECKING(if union initialization works) + AC_CACHE_VAL(pike_cv_have_union_init, [ +  AC_TRY_COMPILE([], [ +  struct foo {int a; char *b;}; +  struct bar {int c[2];}; +  union anything +  { +  struct foo *foo; +  struct bar *bar; +  }; +  struct svalue +  { +  unsigned type; +  unsigned subtype; +  union anything u; +  }; +  struct svalue my_svalue = {0, 0, {{17, "17"}}}; +  ], pike_cv_have_union_init=yes, pike_cv_have_union_init=no)]) + AC_MSG_RESULT($pike_cv_have_union_init) + if test "$pike_cv_have_union_init" = yes; then +  AC_DEFINE(HAVE_UNION_INIT) + fi +  + ####################################################################### +    # Set info about shared libraries.   AC_SUBST(SO)   AC_SUBST(LDSHARED)