#include "../struc/wobject.h"
#include "testobjc.h"


@implementation Number

- init:(double)d
{
  _number=d;
  return self;
}

- (int)intValue
{
  return (int)_number;
}

- (double)doubleValue
{
  return _number;
}

@end

void testobjc__Fv(void){
  id anObject;
  printf("I am in Objective-C\n");
  inCpp__Fv();
  anObject=[WDCObject alloc];
  printf("I am in Objective-C %s\n", [[anObject class] name]);
}

int function__Fi(int i){
  id number=[[Number alloc] init:(double)i];
  i=[number intValue]+10;
  [number free];
  return i;
}

double mywork__Fd(double d){
  id number=[[Number alloc] init:d];
  d=[number doubleValue]+5;
  [number free];
  return d;
}
