This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: try/finally in GNU C


"Steven Bosscher" <stevenb.gcc@gmail.com> writes:

| On 6/16/06, Mike Stump <mrs@apple.com> wrote:
| > foo() {
| >    int i = 99;
| >    __builtin_setjmp(A)
| >    if (i) {
| >      print i
| >      --i;
| >      __builtin_longjump(A);
| >    }
| >
| > It used to not infinite loop, now it does.
| >
| 
| We had an example just like this on IRC only a few weeks ago. ISTR it
| was decided that this triggers undefined behavior by C99 7.13.2.1 sub
| 3.

For the bootstrapping problem I mentioned earlier, they added volatile
to variables in the scope but it did not change anything.  [ They
tried that despite the uncertainty of "volatile"  semantics in GCC/gcc
in the past, and despite they could not afford to do it in general ]

-- Gaby


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]