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