summaryrefslogtreecommitdiff
path: root/gcc/c-family/c-objc.h
diff options
context:
space:
mode:
authorNicola Pero <nicola.pero@meta-innovation.com>2010-12-06 00:56:06 +0000
committerNicola Pero <nicola@gcc.gnu.org>2010-12-06 00:56:06 +0000
commit61d3ce2026946a577515bb1948874a3d8ffa97d6 (patch)
treef19d72f21c2800be50aed27ab677db5388d44de5 /gcc/c-family/c-objc.h
parent7de6ba7a0bf338489274404b854f5fb84f63c731 (diff)
downloadgcc-61d3ce2026946a577515bb1948874a3d8ffa97d6.tar.gz
In gcc/: 2010-12-06 Nicola Pero <nicola.pero@meta-innovation.com>
In gcc/: 2010-12-06 Nicola Pero <nicola.pero@meta-innovation.com> * c-family/c-common.h: Removed the declarations of all the objc_ callbacks, and moved them into c-objc.h. Removed objc_ivar_visibility_kind and moved it into c-objc.h. * c-family/c-objc.h: New file. * c-family/c-common.c: Include c-objc.h. * c-family/c-format.c: Same change. * c-family/stub-objc.c: Same change. * c-decl.c: Include c-family/c-objc.h. * c-parser.c: Same change. * c-typeck.c: Same change. * c-config-lang.in (gtfiles): Added c-family/c-objc.h. * Makefile.in (c-decl.o): Depend on c-family/c-objc.h. (c-parser.o): same change. (c-typeck.o): Same change. (c-family/c-format.o): Same change. (c-family/stub-objc.o): Same change. (c-family/c-common.o): Same change. (PLUGIN_HEADERS): Added c-family/c-objc.h. In gcc/cp/: 2010-12-06 Nicola Pero <nicola.pero@meta-innovation.com> * call.c: Include c-family/c-objc.h. * decl.c: Same change. * decl2.c: Same change. * error.c: Same change. * lex.c: Same change. * parser.c: Same change. * pt.c: Same change. * semantics.c: Same change. * typeck.c: Same change. * Make-lang.in (cp/decl.o): Depend on c-family/c-objc.h. (cp/decl2.o): Same change. (cp/call.o): Same change. (cp/error.o): Same change. (cp/lex.o): Same change. (cp/parser.o): Same change. (cp/pt.o): Same change. (cp/semantics.o): Same change. (cp/typeck.o): Same change. * config-lang.in (gtfiles): Added c-family/c-objc.h. In gcc/objc/: 2010-12-06 Nicola Pero <nicola.pero@meta-innovation.com> * objc-act.c: Include c-family/c-objc.h. * objc-lang.c: Same change. * Make-lang.in (objc/objc-act.o): Depend on c-family/c-objc.h. (objc/objc-lang.o): Same change. * config-lang.in (gtfiles): Added c-family/c-objc.h. In gcc/objcp/: 2010-12-06 Nicola Pero <nicola.pero@meta-innovation.com> * config-lang.in (gtfiles): Added c-family/c-objc.h. * Make-lang.in (objcp/objcp-act.o): Depend on c-family/c-objc.h. (objcp/objcp-lang.o): Same change. (objcp/objcp-decl.o): Same change. * objcp-lang.c: Include c-family/c-objc.h. * objcp-decl.c: Same change. From-SVN: r167481
Diffstat (limited to 'gcc/c-family/c-objc.h')
-rw-r--r--gcc/c-family/c-objc.h115
1 files changed, 115 insertions, 0 deletions
diff --git a/gcc/c-family/c-objc.h b/gcc/c-family/c-objc.h
new file mode 100644
index 00000000000..4089293eee3
--- /dev/null
+++ b/gcc/c-family/c-objc.h
@@ -0,0 +1,115 @@
+/* Definitions of Objective-C front-end entry points used for C and C++.
+ Copyright (C) 1987, 1993, 1994, 1995, 1997, 1998,
+ 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2007, 2008, 2009, 2010
+ Free Software Foundation, Inc.
+
+This file is part of GCC.
+
+GCC is free software; you can redistribute it and/or modify it under
+the terms of the GNU General Public License as published by the Free
+Software Foundation; either version 3, or (at your option) any later
+version.
+
+GCC is distributed in the hope that it will be useful, but WITHOUT ANY
+WARRANTY; without even the implied warranty of MERCHANTABILITY or
+FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+for more details.
+
+You should have received a copy of the GNU General Public License
+along with GCC; see the file COPYING3. If not see
+<http://www.gnu.org/licenses/>. */
+
+#ifndef GCC_C_COMMON_OBJC_H
+#define GCC_C_COMMON_OBJC_H
+
+/* ObjC ivar visibility types. */
+typedef enum objc_ivar_visibility_kind {
+ OBJC_IVAR_VIS_PROTECTED = 0,
+ OBJC_IVAR_VIS_PUBLIC = 1,
+ OBJC_IVAR_VIS_PRIVATE = 2,
+ OBJC_IVAR_VIS_PACKAGE = 3
+} objc_ivar_visibility_kind;
+
+/* Objective-C / Objective-C++ entry points. */
+
+/* The following ObjC/ObjC++ functions are called by the C and/or C++
+ front-ends; they all must have corresponding stubs in stub-objc.c. */
+extern void objc_write_global_declarations (void);
+extern tree objc_is_class_name (tree);
+extern tree objc_is_object_ptr (tree);
+extern void objc_check_decl (tree);
+extern void objc_check_global_decl (tree);
+extern tree objc_common_type (tree, tree);
+extern bool objc_compare_types (tree, tree, int, tree);
+extern bool objc_have_common_type (tree, tree, int, tree);
+extern bool objc_diagnose_private_ivar (tree);
+extern void objc_volatilize_decl (tree);
+extern tree objc_rewrite_function_call (tree, tree);
+extern tree objc_message_selector (void);
+extern tree objc_lookup_ivar (tree, tree);
+extern void objc_clear_super_receiver (void);
+extern int objc_is_public (tree, tree);
+extern tree objc_is_id (tree);
+extern void objc_declare_alias (tree, tree);
+extern void objc_declare_class (tree);
+extern void objc_declare_protocols (tree, tree);
+extern tree objc_build_message_expr (tree);
+extern tree objc_finish_message_expr (tree, tree, tree);
+extern tree objc_build_selector_expr (location_t, tree);
+extern tree objc_build_protocol_expr (tree);
+extern tree objc_build_encode_expr (tree);
+extern tree objc_build_string_object (tree);
+extern tree objc_get_protocol_qualified_type (tree, tree);
+extern tree objc_get_class_reference (tree);
+extern tree objc_get_class_ivars (tree);
+extern tree objc_get_interface_ivars (tree);
+extern void objc_start_class_interface (tree, tree, tree, tree);
+extern void objc_start_category_interface (tree, tree, tree, tree);
+extern void objc_start_protocol (tree, tree, tree);
+extern void objc_continue_interface (void);
+extern void objc_finish_interface (void);
+extern void objc_start_class_implementation (tree, tree);
+extern void objc_start_category_implementation (tree, tree);
+extern void objc_continue_implementation (void);
+extern void objc_finish_implementation (void);
+extern void objc_set_visibility (objc_ivar_visibility_kind);
+extern tree objc_build_method_signature (bool, tree, tree, tree, bool);
+extern void objc_add_method_declaration (bool, tree, tree);
+extern bool objc_start_method_definition (bool, tree, tree);
+extern void objc_finish_method_definition (tree);
+extern void objc_add_instance_variable (tree);
+extern tree objc_build_keyword_decl (tree, tree, tree, tree);
+extern tree objc_build_throw_stmt (location_t, tree);
+extern void objc_begin_try_stmt (location_t, tree);
+extern tree objc_finish_try_stmt (void);
+extern void objc_begin_catch_clause (tree);
+extern void objc_finish_catch_clause (void);
+extern void objc_build_finally_clause (location_t, tree);
+extern tree objc_build_synchronized (location_t, tree, tree);
+extern int objc_static_init_needed_p (void);
+extern tree objc_generate_static_init_call (tree);
+extern tree objc_generate_write_barrier (tree, enum tree_code, tree);
+extern void objc_set_method_opt (bool);
+extern void objc_finish_foreach_loop (location_t, tree, tree, tree, tree, tree);
+extern bool objc_method_decl (enum tree_code);
+extern void objc_add_property_declaration (location_t, tree, bool, bool, bool,
+ bool, bool, bool, tree, tree);
+extern tree objc_maybe_build_component_ref (tree, tree);
+extern tree objc_build_class_component_ref (tree, tree);
+extern tree objc_maybe_build_modify_expr (tree, tree);
+extern tree objc_build_incr_expr_for_property_ref (location_t, enum tree_code,
+ tree, tree);
+extern void objc_add_synthesize_declaration (location_t, tree);
+extern void objc_add_dynamic_declaration (location_t, tree);
+extern const char * objc_maybe_printable_name (tree, int);
+extern bool objc_is_property_ref (tree);
+extern bool objc_string_ref_type_p (tree);
+extern void objc_check_format_arg (tree, tree);
+extern void objc_finish_function (void);
+
+/* The following are provided by the C and C++ front-ends, and called by
+ ObjC/ObjC++. */
+extern void *objc_get_current_scope (void);
+extern void objc_mark_locals_volatile (void *);
+
+#endif /* ! GCC_C_COMMON_OBJC_H */