[Bug objc/23381] New: [4.1 Regression] Next runtime objc exceptions are broken
pinskia at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Sat Aug 13 22:33:00 GMT 2005
Take the following test (which I am about to commit to the testsuite, it is from PR 22492), we should
not abort:
#include <objc/Object.h>
#include <stdio.h>
#include <stdlib.h>
static int made_try = 0;
int
thrower_try_body()
{
made_try++;
return (0);
}
static int made_finally = 0;
int
finally_body()
{
made_finally++;
return (0);
}
int
thrower()
{
@try
{
thrower_try_body();
@throw [Object new];
}
@finally
{
finally_body();
}
return 0;
}
static int made_catch = 0;
int
main(int ac, char *av[])
{
@try
{
thrower();
}
@catch (id exc)
{
made_catch++;
[exc free];
}
if (made_try != 1)
abort ();
if (made_finally != 1)
abort ();
if (made_catch != 1)
abort ();
}
It worked in 4.0.0 20050113 so this is a regression.
--
Summary: [4.1 Regression] Next runtime objc exceptions are broken
Product: gcc
Version: 4.1.0
Status: UNCONFIRMED
Keywords: wrong-code
Severity: normal
Priority: P2
Component: objc
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: pinskia at gcc dot gnu dot org
CC: gcc-bugs at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23381
More information about the Gcc-bugs
mailing list