OSDN Git Service

In gcc/:
[pf3gnuchains/gcc-fork.git] / gcc / c-family / stub-objc.c
1 /* Stub functions for Objective-C and Objective-C++ routines
2    that are called from within the C and C++ front-ends,
3    respectively.
4    Copyright (C) 1991, 1995, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
5    2004, 2005, 2007, 2009, 2010 Free Software Foundation, Inc.
6
7 This file is part of GCC.
8
9 GCC is free software; you can redistribute it and/or modify it under
10 the terms of the GNU General Public License as published by the Free
11 Software Foundation; either version 3, or (at your option) any later
12 version.
13
14 GCC is distributed in the hope that it will be useful, but WITHOUT ANY
15 WARRANTY; without even the implied warranty of MERCHANTABILITY or
16 FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
17 for more details.
18
19 You should have received a copy of the GNU General Public License
20 along with GCC; see the file COPYING3.  If not see
21 <http://www.gnu.org/licenses/>.  */
22
23 #include "config.h"
24 #include "system.h"
25 #include "coretypes.h"
26 #include "tree.h"
27 #include "c-common.h"
28
29 tree
30 objc_is_class_name (tree ARG_UNUSED (arg))
31 {
32   return 0;
33 }
34
35 tree
36 objc_is_id (tree ARG_UNUSED (arg))
37 {
38   return 0;
39 }
40
41 tree
42 objc_is_object_ptr (tree ARG_UNUSED (arg))
43 {
44   return 0;
45 }
46
47 bool objc_diagnose_private_ivar (tree ARG_UNUSED (arg))
48 {
49   return false;
50 }
51
52 tree
53 objc_lookup_ivar (tree other, tree ARG_UNUSED (arg))
54 {
55   /* Just use whatever C/C++ found.  */
56   return other;
57 }
58
59 void
60 objc_check_decl (tree ARG_UNUSED (decl))
61 {
62 }
63
64 void
65 objc_check_global_decl (tree ARG_UNUSED (decl))
66 {
67 }
68
69 tree
70 objc_non_volatilized_type (tree type)
71 {
72   return type;
73 }
74
75 tree
76 objc_common_type (tree ARG_UNUSED (type1), tree ARG_UNUSED (type2))
77 {
78   return 0;
79 }
80
81 bool
82 objc_compare_types (tree ARG_UNUSED (ltyp), tree ARG_UNUSED (rtyp),
83                     int ARG_UNUSED (argno), tree ARG_UNUSED (callee))
84 {
85   return false;
86 }
87
88 bool
89 objc_have_common_type (tree ARG_UNUSED (ltyp), tree ARG_UNUSED (rtyp),
90                        int ARG_UNUSED (argno), tree ARG_UNUSED (callee))
91 {
92   return false;
93 }
94
95 void
96 objc_volatilize_decl (tree ARG_UNUSED (decl))
97 {
98 }
99
100 bool
101 objc_type_quals_match (tree ARG_UNUSED (ltyp), tree ARG_UNUSED (rtyp))
102 {
103   return false;
104 }
105
106 tree
107 objc_rewrite_function_call (tree function, tree ARG_UNUSED (first_param))
108 {
109   return function;
110 }
111
112 tree
113 objc_message_selector (void)
114 {
115   return 0;
116 }
117
118 void
119 objc_declare_alias (tree ARG_UNUSED (alias), tree ARG_UNUSED (orig))
120 {
121 }
122
123 void
124 objc_declare_class (tree ARG_UNUSED (list))
125 {
126 }
127
128 void
129 objc_declare_protocols (tree ARG_UNUSED (list), tree ARG_UNUSED (attributes))
130 {
131 }
132
133 void
134 objc_start_protocol (tree ARG_UNUSED (proto),
135                      tree ARG_UNUSED (protorefs),
136                      tree ARG_UNUSED (attribs))
137 {
138 }
139
140 void 
141 objc_set_method_opt (bool ARG_UNUSED (optional))
142 {
143 }
144
145 void
146 objc_start_class_interface (tree ARG_UNUSED (name),
147                             tree ARG_UNUSED (super),
148                             tree ARG_UNUSED (protos),
149                             tree ARG_UNUSED (attribs))
150 {
151 }
152
153 void
154 objc_start_category_interface (tree ARG_UNUSED (name),
155                                tree ARG_UNUSED (categ),
156                                tree ARG_UNUSED (protos),
157                                tree ARG_UNUSED (attribs))
158 {
159 }
160
161 void
162 objc_continue_interface (void)
163 {
164 }
165
166 void
167 objc_finish_interface (void)
168 {
169 }
170
171 void
172 objc_add_instance_variable (tree ARG_UNUSED (decl))
173 {
174 }
175
176 void
177 objc_set_visibility (objc_ivar_visibility_kind ARG_UNUSED (vis))
178 {
179 }
180
181 void
182 objc_start_class_implementation (tree ARG_UNUSED (name),
183                                  tree ARG_UNUSED (super))
184 {
185 }
186
187 void
188 objc_start_category_implementation (tree ARG_UNUSED (name),
189                                     tree ARG_UNUSED (categ))
190 {
191 }
192
193 void
194 objc_continue_implementation (void)
195 {
196 }
197
198 void
199 objc_clear_super_receiver (void)
200 {
201 }
202
203 void
204 objc_finish_implementation (void)
205 {
206 }
207
208 void
209 objc_add_method_declaration (bool ARG_UNUSED (is_class_method),
210                              tree ARG_UNUSED (signature),
211                              tree ARG_UNUSED (attributes))
212 {
213 }
214
215 bool
216 objc_start_method_definition (bool ARG_UNUSED (is_class_method),
217                               tree ARG_UNUSED (signature),
218                               tree ARG_UNUSED (attributes))
219 {
220   return true;
221 }
222
223 void
224 objc_finish_method_definition (tree ARG_UNUSED (fndecl))
225 {
226 }
227
228 bool 
229 objc_method_decl (enum tree_code ARG_UNUSED(opcode))
230 {
231   return false;
232 }
233
234 tree
235 objc_build_keyword_decl (tree ARG_UNUSED (selector),
236                          tree ARG_UNUSED (type),
237                          tree ARG_UNUSED (identifier),
238                          tree ARG_UNUSED (attributes))
239 {
240   return 0;
241 }
242
243 tree
244 objc_build_method_signature (bool ARG_UNUSED (is_class_method),
245                              tree ARG_UNUSED (rettype),
246                              tree ARG_UNUSED (selectors),
247                              tree ARG_UNUSED (optparms),
248                              bool ARG_UNUSED (ellipsis))
249 {
250   return 0;
251 }
252
253 tree
254 objc_build_encode_expr (tree ARG_UNUSED (expr))
255 {
256   return 0;
257 }
258
259 tree
260 objc_build_protocol_expr (tree ARG_UNUSED (expr))
261 {
262   return 0;
263 }
264
265 tree
266 objc_build_selector_expr (location_t ARG_UNUSED (loc), tree ARG_UNUSED (expr))
267 {
268   return 0;
269 }
270
271 tree
272 objc_build_message_expr (tree ARG_UNUSED (expr))
273 {
274   return 0;
275 }
276
277 tree
278 objc_build_string_object (tree ARG_UNUSED (str))
279 {
280   return 0;
281 }
282
283 tree
284 objc_get_class_reference (tree ARG_UNUSED (name))
285 {
286   return 0;
287 }
288
289 tree
290 objc_get_interface_ivars (tree ARG_UNUSED (fieldlist))
291 {
292   return 0;
293 }
294
295 tree
296 objc_get_protocol_qualified_type (tree ARG_UNUSED (name),
297                                   tree ARG_UNUSED (protos))
298 {
299   return 0;
300 }
301
302 int
303 objc_static_init_needed_p (void)
304 {
305   return 0;
306 }
307
308 tree
309 objc_generate_static_init_call (tree ARG_UNUSED (ctors))
310 {
311   return 0;
312 }
313
314 int
315 objc_is_public (tree ARG_UNUSED (expr), tree ARG_UNUSED (identifier))
316 {
317   return 1;
318 }
319
320 tree
321 objc_get_class_ivars (tree ARG_UNUSED (name))
322 {
323   return 0;
324 }
325
326 void
327 objc_add_property_declaration (location_t ARG_UNUSED (location), 
328                                tree ARG_UNUSED (decl),
329                                bool ARG_UNUSED (parsed_property_readonly),
330                                bool ARG_UNUSED (parsed_property_readwrite),
331                                bool ARG_UNUSED (parsed_property_assign),
332                                bool ARG_UNUSED (parsed_property_retain),
333                                bool ARG_UNUSED (parsed_property_copy),
334                                bool ARG_UNUSED (parsed_property_nonatomic),
335                                tree ARG_UNUSED (parsed_property_getter_ident),
336                                tree ARG_UNUSED (parsed_property_setter_ident))
337 {
338 }
339
340 bool
341 objc_is_property_ref (tree ARG_UNUSED (node))
342 {
343   return 0;
344 }
345
346 tree
347 objc_maybe_build_component_ref (tree ARG_UNUSED (datum), tree ARG_UNUSED (component))
348 {
349   return 0;
350 }
351
352 tree
353 objc_build_class_component_ref (tree ARG_UNUSED (datum), tree ARG_UNUSED (component))
354 {
355   return 0;
356 }
357
358 tree
359 objc_maybe_build_modify_expr (tree ARG_UNUSED (lhs), tree ARG_UNUSED (rhs))
360 {
361   return 0;
362 }
363
364 tree
365 objc_build_incr_expr_for_property_ref (location_t ARG_UNUSED (location),
366                                        enum tree_code ARG_UNUSED (code),
367                                        tree ARG_UNUSED (argument),
368                                        tree ARG_UNUSED (increment))
369 {
370   return 0;
371 }
372
373 void
374 objc_add_synthesize_declaration (location_t ARG_UNUSED (start_locus), 
375                                  tree ARG_UNUSED (property_and_ivar_list))
376 {
377 }
378
379 void
380 objc_add_dynamic_declaration (location_t ARG_UNUSED (start_locus), 
381                               tree ARG_UNUSED (property_list))
382 {
383 }
384
385 const char *
386 objc_maybe_printable_name (tree ARG_UNUSED (decl), 
387                            int ARG_UNUSED (v))
388 {
389   return NULL;
390 }
391
392 tree
393 objc_build_throw_stmt (location_t ARG_UNUSED (loc), tree ARG_UNUSED (expr))
394 {
395   return 0;
396 }
397
398 tree
399 objc_build_synchronized (location_t ARG_UNUSED (start_locus),
400                          tree ARG_UNUSED (mutex), tree ARG_UNUSED (body))
401 {
402   return 0;
403 }
404
405 void
406 objc_begin_try_stmt (location_t ARG_UNUSED (try_locus), tree ARG_UNUSED (body))
407 {
408 }
409
410 void
411 objc_begin_catch_clause (tree ARG_UNUSED (decl))
412 {
413 }
414
415 void
416 objc_finish_catch_clause (void)
417 {
418 }
419
420 void
421 objc_build_finally_clause (location_t ARG_UNUSED (finally_locus),
422                            tree ARG_UNUSED (body))
423 {
424 }
425
426 tree
427 objc_finish_try_stmt (void)
428 {
429   return 0;
430 }
431
432 tree
433 objc_generate_write_barrier (tree ARG_UNUSED (lhs),
434                              enum tree_code ARG_UNUSED (modifycode),
435                              tree ARG_UNUSED (rhs))
436 {
437   return 0;
438 }
439
440 void
441 objc_finish_foreach_loop (location_t ARG_UNUSED (location), tree ARG_UNUSED (object_expression),
442                           tree ARG_UNUSED (collection_expression), tree ARG_UNUSED (for_body),
443                           tree ARG_UNUSED (break_label), tree ARG_UNUSED (continue_label))
444 {
445   return;
446 }
447
448 void
449 objc_write_global_declarations (void)
450 {
451 }
452
453 bool
454 objc_string_ref_type_p (tree ARG_UNUSED (strp))
455 {
456    return false;
457 }
458
459 void
460 objc_check_format_arg (tree ARG_UNUSED (format_arg), 
461                        tree ARG_UNUSED (args_list))
462 {
463 }