mirror of
				https://gitlab.com/freepascal.org/fpc/source.git
				synced 2025-10-31 10:31:44 +01:00 
			
		
		
		
	
		
			
				
	
	
		
			17 lines
		
	
	
		
			265 B
		
	
	
	
		
			ObjectPascal
		
	
	
	
	
	
			
		
		
	
	
			17 lines
		
	
	
		
			265 B
		
	
	
	
		
			ObjectPascal
		
	
	
	
	
	
| Program Example10;
 | |
| 
 | |
| Uses strings;
 | |
| 
 | |
| { Program to demonstrate the StrMove function. }
 | |
| 
 | |
| Const P1 : PCHAR = 'This is a pchar string.';
 | |
| 
 | |
| 
 | |
| Var P2 : Pchar;
 | |
|        
 | |
| begin
 | |
|   P2:=StrAlloc(StrLen(P1)+1);
 | |
|   StrMove (P2,P1,StrLen(P1)+1); { P2:=P1 }
 | |
|   Writeln ('P2 = ',P2);
 | |
| end.
 | 
