~iaz/+junk/demo-bindings

« back to all changes in this revision

Viewing changes to src/objc-demo.m

  • Committer: ivan.a.zorin at gmail
  • Date: 2011-11-16 16:16:00 UTC
  • Revision ID: ivan.a.zorin@gmail.com-20111116161600-59pn7uz60ksqcpxh
demo-bindings: add objective-c bindings support

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
 
 
2
#import <Foundation/Foundation.h>
 
3
#import <Library_objc.h>
 
4
 
 
5
int main(int argc, const char *argv[])
 
6
{
 
7
        NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
 
8
        
 
9
        [Library ClassMethod];
 
10
        [Library ClassFunction];
 
11
        
 
12
        Library *l = [[Library alloc] init];
 
13
        
 
14
        [l ObjectMethod];
 
15
        [l ObjectFunction];
 
16
        
 
17
        [l dealloc];
 
18
        [pool drain];
 
19
        
 
20
        return 0;
 
21
}
 
22