#import <Foundation/Foundation.h>

#import "TestExceptionPersonality.h"

@implementation Tester

- (Tester *)init
{
  if ((self = [super init]) != nil) {
    _oc = [[ObjcClass alloc] initWithName:@"MyTest"];
  }
  return self;
}

- (void)poke
{
  NSLog(@"Starting poke");
  @try {
  } @catch(...) {
  } @finally {
    NSLog(@"Finally cause - poking");
    NS_DURING
      [_oc poke];
    NS_HANDLER
      [localException raise];
    NS_ENDHANDLER
  }
}

- (void)pokeCpp
{
  [_oc pokeCpp];
}

- (void)dealloc
{
  [_oc release];
  [super dealloc];
}

@end
