mirror of
				https://gitlab.com/freepascal.org/fpc/source.git
				synced 2025-11-04 02:19:22 +01:00 
			
		
		
		
	
		
			
				
	
	
		
			29 lines
		
	
	
		
			468 B
		
	
	
	
		
			ObjectPascal
		
	
	
	
	
	
			
		
		
	
	
			29 lines
		
	
	
		
			468 B
		
	
	
	
		
			ObjectPascal
		
	
	
	
	
	
{ %target=darwin }
 | 
						|
{ %cpu=powerpc,powerpc64,i386,x86_64,arm }
 | 
						|
{ %recompile }
 | 
						|
 | 
						|
{ Written by Jonas Maebe in 2009, released into the public domain }
 | 
						|
 | 
						|
{$modeswitch objectivec1}
 | 
						|
 | 
						|
uses
 | 
						|
  uobjc27a,uobjc27b;
 | 
						|
 | 
						|
var
 | 
						|
  a: ta;
 | 
						|
  c: tachild;
 | 
						|
 | 
						|
begin
 | 
						|
  a:=ta(ta.alloc).init;
 | 
						|
  if a.da_categorymethod<>2 then
 | 
						|
    halt(1);
 | 
						|
  a.release;
 | 
						|
 | 
						|
  c:=tachild(tachild.alloc).init;
 | 
						|
  if c.da_categorymethod<>2 then
 | 
						|
    halt(2);
 | 
						|
  if c.eachild_categorymethod<>3 then
 | 
						|
    halt(3);
 | 
						|
  c.release;
 | 
						|
end.
 |