1 /* Processed by ecpg (regression mode) */
2 /* These include files are added by the preprocessor */
3 #include <ecpglib.h>
4 #include <ecpgerrno.h>
5 #include <sqlca.h>
6 /* Needed for informix compatibility */
7 #include <ecpg_informix.h>
8 /* End of automatic include section */
9 #define ECPGdebug(X,Y) ECPGdebug((X)+100,(Y))
10 
11 #line 1 "charfuncs.pgc"
12 #include <stdio.h>
13 #include <stdlib.h>
14 #include <sqltypes.h>
15 
main(void)16 int main(void)
17 {
18 	char t1[] = "abc  def  ghi  ";
19 	          /* 123456789012345 */
20 	char buf[50];
21 	int k;
22 
23 	printf("t1: _%s_\n", t1);
24 	rupshift(t1);
25 	printf("t1: _%s_\n", t1);
26 
27 	k = 2;
28 	ldchar(t1, k, buf);
29 	printf("byleng(t1, %d): %d, ldchar: _%s_\n", k, byleng(t1, k), buf);
30 	k = 5;
31 	ldchar(t1, k, buf);
32 	printf("byleng(t1, %d): %d, ldchar: _%s_\n", k, byleng(t1, k), buf);
33 	k = 9;
34 	ldchar(t1, k, buf);
35 	printf("byleng(t1, %d): %d, ldchar: _%s_\n", k, byleng(t1, k), buf);
36 	k = 15;
37 	ldchar(t1, k, buf);
38 	printf("byleng(t1, %d): %d, ldchar: _%s_\n", k, byleng(t1, k), buf);
39 
40 
41 	return 0;
42 }
43