--------------5882E66C177C4E5ED3A7EF8D Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Volker Barthelmann wrote: > On Mon, 6 Oct 1997, Uncle George wrote: > The code is basically broken. Reading another member of a union than the > one which was last written causes implementation defined behaviour (IMHO > it should even be undefined behaviour). This is not a broken feature, but rather a porting implimentation problem. The long on alpha is 64 bit, the double on a alpha is 64 bit. a union would make the space ONE. in reality quite a few people do this for the exact same reasons, so long as u understand how things are getting stored ( including packed/unpacked structs!) BTW. i ran the pgm without gdb, and it prints out the right contents, I ran GDB without any breakpoints, and the printed values were correct. BUT running gdb, using next stepping caused the values to be mixed up. SO I GUESS its a gdb/ptrace bug! (fudge!!!) > -- > To unsubscribe: send e-mail to axp-list-request@redhat.com with > 'unsubscribe' as the subject. Do not send it to axp-list@redhat.com --------------5882E66C177C4E5ED3A7EF8D Content-Type: text/html; charset=us-ascii Content-Transfer-Encoding: 7bit   Volker Barthelmann wrote: On Mon, 6 Oct 1997, Uncle George wrote: The code is basically broken. Reading another member of a union than the one which was last written causes implementation defined behaviour (IMHO it should even be undefined behaviour). This is not a broken feature, but rather a porting implimentation problem. The long on alpha is 64 bit, the double on a alpha is 64 bit. a union would make the space ONE. in reality quite a few people do this for the exact same reasons, so long as u understand how things are getting stored ( including packed/unpacked structs!) BTW. i ran the pgm without gdb, and it prints out the right contents,     I ran GDB without any breakpoints, and the printed values were correct.                 BUT     running gdb, using  next stepping caused the values to be mixed up. SO I GUESS its a gdb/ptrace bug! (fudge!!!) -- To unsubscribe: send e-mail to axp-list-request@redhat.com with 'unsubscribe' as the subject.  Do not send it to axp-list@redhat.com   --------------5882E66C177C4E5ED3A7EF8D-- -- To unsubscribe: send e-mail to axp-list-request@redhat.com with 'unsubscribe' as the subject. Do not send it to axp-list@redhat.com