2 * Copyright (C) 2004, The Perl Foundation.
6 * Contains accessor functions for globals
7 * Data Structure and Algorithms:
13 #ifndef PARROT_GLOBAL_H_GUARD
14 #define PARROT_GLOBAL_H_GUARD
16 /* HEADERIZER BEGIN: src/global.c */
19 PARROT_WARN_UNUSED_RESULT
20 PARROT_CAN_RETURN_NULL
21 PMC
* Parrot_find_global_cur(PARROT_INTERP
,
22 ARGIN_NULLOK(STRING
*globalname
))
23 __attribute__nonnull__(1);
26 PARROT_WARN_UNUSED_RESULT
27 PARROT_CAN_RETURN_NULL
28 PMC
* Parrot_find_global_k(PARROT_INTERP
,
29 ARGIN_NULLOK(PMC
*pmc_key
),
30 ARGIN(STRING
*globalname
))
31 __attribute__nonnull__(1)
32 __attribute__nonnull__(3);
35 PARROT_WARN_UNUSED_RESULT
36 PARROT_CAN_RETURN_NULL
37 PMC
* Parrot_find_global_n(PARROT_INTERP
,
38 ARGIN_NULLOK(PMC
*ns
),
39 ARGIN_NULLOK(STRING
*globalname
))
40 __attribute__nonnull__(1);
43 PARROT_WARN_UNUSED_RESULT
44 PARROT_CANNOT_RETURN_NULL
45 PMC
* Parrot_find_global_op(PARROT_INTERP
,
47 ARGIN(STRING
*globalname
),
48 ARGIN_NULLOK(void *next
))
49 __attribute__nonnull__(1)
50 __attribute__nonnull__(2)
51 __attribute__nonnull__(3);
54 PARROT_WARN_UNUSED_RESULT
55 PARROT_CAN_RETURN_NULL
56 PMC
* Parrot_find_global_s(PARROT_INTERP
,
57 ARGIN_NULLOK(STRING
*str_key
),
58 ARGIN_NULLOK(STRING
*globalname
))
59 __attribute__nonnull__(1);
62 PARROT_WARN_UNUSED_RESULT
63 PARROT_CAN_RETURN_NULL
64 PMC
* Parrot_find_name_op(PARROT_INTERP
,
67 __attribute__nonnull__(1)
68 __attribute__nonnull__(2);
71 PARROT_WARN_UNUSED_RESULT
72 PARROT_CAN_RETURN_NULL
73 PMC
* Parrot_get_global(PARROT_INTERP
,
74 ARGIN_NULLOK(PMC
*ns
),
75 ARGIN_NULLOK(STRING
*globalname
))
76 __attribute__nonnull__(1);
79 PARROT_WARN_UNUSED_RESULT
80 PARROT_CAN_RETURN_NULL
81 PMC
* Parrot_get_namespace_autobase(PARROT_INTERP
, ARGIN_NULLOK(PMC
*key
))
82 __attribute__nonnull__(1);
85 PARROT_WARN_UNUSED_RESULT
86 PARROT_CAN_RETURN_NULL
87 PMC
* Parrot_get_namespace_keyed(PARROT_INTERP
,
89 ARGIN_NULLOK(PMC
*pmc_key
))
90 __attribute__nonnull__(1)
91 __attribute__nonnull__(2);
94 PARROT_WARN_UNUSED_RESULT
95 PARROT_CAN_RETURN_NULL
96 PMC
* Parrot_get_namespace_keyed_str(PARROT_INTERP
,
98 ARGIN_NULLOK(STRING
*str_key
))
99 __attribute__nonnull__(1)
100 __attribute__nonnull__(2);
103 PARROT_WARN_UNUSED_RESULT
104 PARROT_CAN_RETURN_NULL
105 PMC
* Parrot_make_namespace_autobase(PARROT_INTERP
, ARGIN_NULLOK(PMC
*key
))
106 __attribute__nonnull__(1);
109 PARROT_WARN_UNUSED_RESULT
110 PARROT_CAN_RETURN_NULL
111 PMC
* Parrot_make_namespace_keyed(PARROT_INTERP
,
113 ARGIN_NULLOK(PMC
*pmc_key
))
114 __attribute__nonnull__(1)
115 __attribute__nonnull__(2);
118 PARROT_WARN_UNUSED_RESULT
119 PARROT_CAN_RETURN_NULL
120 PMC
* Parrot_make_namespace_keyed_str(PARROT_INTERP
,
122 ARGIN_NULLOK(STRING
*str_key
))
123 __attribute__nonnull__(1)
124 __attribute__nonnull__(2);
127 PARROT_WARN_UNUSED_RESULT
128 PARROT_CAN_RETURN_NULL
129 PMC
* Parrot_ns_get_name(PARROT_INTERP
, ARGIN(PMC
*_namespace
))
130 __attribute__nonnull__(1)
131 __attribute__nonnull__(2);
134 void Parrot_set_global(PARROT_INTERP
,
135 ARGIN_NULLOK(PMC
*ns
),
136 ARGIN_NULLOK(STRING
*globalname
),
137 ARGIN_NULLOK(PMC
*val
))
138 __attribute__nonnull__(1);
141 void Parrot_store_global_cur(PARROT_INTERP
,
142 ARGIN_NULLOK(STRING
*globalname
),
143 ARGIN_NULLOK(PMC
*val
))
144 __attribute__nonnull__(1);
147 void Parrot_store_global_k(PARROT_INTERP
,
149 ARGIN_NULLOK(STRING
*globalname
),
150 ARGIN_NULLOK(PMC
*val
))
151 __attribute__nonnull__(1)
152 __attribute__nonnull__(2);
155 void Parrot_store_global_n(PARROT_INTERP
,
156 ARGIN_NULLOK(PMC
*ns
),
157 ARGIN_NULLOK(STRING
*globalname
),
158 ARGIN_NULLOK(PMC
*val
))
159 __attribute__nonnull__(1);
162 void Parrot_store_global_s(PARROT_INTERP
,
163 ARGIN_NULLOK(STRING
*str_key
),
164 ARGIN_NULLOK(STRING
*globalname
),
165 ARGIN_NULLOK(PMC
*val
))
166 __attribute__nonnull__(1);
169 void Parrot_store_sub_in_namespace(PARROT_INTERP
, ARGIN(PMC
*sub
))
170 __attribute__nonnull__(1)
171 __attribute__nonnull__(2);
173 /* HEADERIZER END: src/global.c */
175 #endif /* PARROT_GLOBAL_H_GUARD */
179 * c-file-style: "parrot"
181 * vim: expandtab shiftwidth=4: