2 # Copyright (C) 2001-2005, Parrot Foundation.
7 use lib qw( . lib ../lib ../../lib );
9 use Parrot::Test tests => 4;
13 t/pmc/globals.t - Globals and Namespaces
17 % prove t/pmc/globals.t
21 Tests the globals fetch and store operations.
25 pir_output_is( <<'CODE', <<'OUTPUT', "get namespace" );
41 pir_output_is( <<'CODE', <<'OUTPUT', "create namespace" );
45 set_global ["Foo"], "x", f
46 x = get_global ["Foo"], "x"
57 pir_output_is( <<'CODE', <<'OUTPUT', "get namespace - nested" );
60 ns = get_hll_namespace ["Foo"; "Bar"]
65 .namespace ["Foo" ; "Bar"]
73 # this is pretty much taken from PDD 21
74 pir_output_is( <<'CODE', <<'OUTPUT', "get namespace - array" );
75 .namespace ['Foo'; 'Bar']
83 $P0 = split "::", "Foo::Bar::test"
86 $P1 = get_hll_namespace $P0
98 # cperl-indent-level: 4
101 # vim: expandtab shiftwidth=4: