Hi, > -----Original Message----- > From: Gcc-help <gcc-help-bounces@xxxxxxxxxxx> On Behalf Of Kacvinsky, > Tom > Sent: Wednesday, May 20, 2020 6:01 PM > To: gcc-help@xxxxxxxxxxx > Subject: GCC 8.3.0 and Ada's foreign_exception > > We have a mixed C++/Ada development environment. One of our C++ files > throws an exception that is not caught in C++, but is caught in Ada. The Ada > exception type is foreign_exception. That is fine, we don't have the > necessary stuff set up so that Ada knows how to handle a C++ exception (I > did see there is a way of doing that by getting RTTI information). > > What is really puzzling is that on different platforms, we get different exit > codes when Ada exits because of the exception. On some platforms it is 0, > on others it is non-zero. Any ideas as to why this happens? I would like to > think that Ada would exit with a consistent exit code between platforms. I > can understand a difference between Windows and Linux, as Windows exit > codes are (at least to me) weird. But we are seeing differences in 32-bit > Linux executables and 64-bit Linux executables. > > Any pointers are appreciated. > One of my more adept colleagues pointed out I am in error. We are getting consistent return codes. I just have to refactor some code that takes into account the foreign_exception we get and how our program exits. Sorry for the noise.