proc main()
{
var a = "hello";
var b = @a;
var c = oadl::protect(b);
var d = oadl::perm(b);
"Constant string a should not be transient but should be readonly\n";
"a.transient(): ", a.transient(), '\n';
"a.readonly(): ", a.readonly(), '\n';
"A copy of a constant string is transient but not readonly\n";
"b.transient(): ", b.transient(), '\n';
"b.readonly(): ", b.readonly(), '\n';
"Protecting a non-constant string is transient *and* readonly\n";
"c.transient(): ", c.transient(), '\n';
"c.readonly(): ", c.readonly(), '\n';
"Promoting a non-constant string to perm makes it non-transient\n";
"d.transient(): ", d.transient(), '\n';
"d.readonly(): ", d.readonly(), '\n';
}