/*
 * $Id: test-ext.c,v 1.3 2012/02/20 08:41:29 vrsieh Exp $
 */

#include <stdio.h>

char globalvar;
char globalstr[1] = { '0' };
static char localvar;
static char localstr[1] = { '0' };

void
func(void)
{
	char tmp;

	printf("%c\n", globalvar);
	printf("%c\n", globalstr[0]);
	printf("%p\n", &globalvar);
	printf("%p\n", globalstr);

	printf("%c\n", localvar);
	printf("%c\n", localstr[0]);
	printf("%p\n", &localvar);
	printf("%p\n", localstr);

	printf("%p\n", func);

	tmp = globalstr[0] + 1;
	globalstr[0] = tmp + 1;
	globalvar = globalstr[0];
	globalstr[0] = globalvar;

	tmp = localstr[0] + 1;
	localstr[0] = tmp + 1;
	localvar = localstr[0];
	localstr[0] = localvar;
}
