Warning: Attempt to read property "date" on null in /usr/local/www/websvn.planix.org/blame.php on line 247

Warning: Attempt to read property "msg" on null in /usr/local/www/websvn.planix.org/blame.php on line 247
WebSVN – tendra.SVN – Blame – //branches/tendra5/src/producers/common/construct/function.h – Rev 2

Subversion Repositories tendra.SVN

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
2 7u83 1
/*
2
    		 Crown Copyright (c) 1997
3
 
4
    This TenDRA(r) Computer Program is subject to Copyright
5
    owned by the United Kingdom Secretary of State for Defence
6
    acting through the Defence Evaluation and Research Agency
7
    (DERA).  It is made available to Recipients with a
8
    royalty-free licence for its use, reproduction, transfer
9
    to other parties and amendment for any purpose not excluding
10
    product development provided that any such use et cetera
11
    shall be deemed to be acceptance of the following conditions:-
12
 
13
        (1) Its Recipients shall ensure that this Notice is
14
        reproduced upon any copies or amended versions of it;
15
 
16
        (2) Any amended version of it shall be clearly marked to
17
        show both the nature of and the organisation responsible
18
        for the relevant amendment or amendments;
19
 
20
        (3) Its onward transfer from a recipient to another
21
        party shall be deemed to be that party's acceptance of
22
        these conditions;
23
 
24
        (4) DERA gives no warranty or assurance as to its
25
        quality or suitability for any purpose and DERA accepts
26
        no liability whatsoever in relation to any use to which
27
        it may be put.
28
*/
29
 
30
 
31
#ifndef FUNCTION_INCLUDED
32
#define FUNCTION_INCLUDED
33
 
34
 
35
/*
36
    FUNCTION DECLARATIONS
37
 
38
    The routines in this module are concerned with the construction and
39
    application of functions.
40
*/
41
 
42
extern void begin_function PROTO_S ( ( IDENTIFIER ) ) ;
43
extern EXP end_function PROTO_S ( ( IDENTIFIER, EXP ) ) ;
44
extern void begin_param PROTO_S ( ( IDENTIFIER ) ) ;
45
extern void end_param PROTO_S ( ( void ) ) ;
46
extern void adjust_param PROTO_S ( ( TYPE ) ) ;
47
extern int function_params PROTO_S ( ( TYPE ) ) ;
48
extern TYPE make_param_type PROTO_S ( ( TYPE, int ) ) ;
49
extern TYPE make_func_type PROTO_S ( ( TYPE, int, CV_SPEC, LIST ( TYPE ) ) ) ;
50
extern CV_SPEC func_linkage PROTO_S ( ( CV_SPEC ) ) ;
51
extern void member_func_type PROTO_S ( ( CLASS_TYPE, unsigned, TYPE ) ) ;
52
extern void check_weak_func PROTO_S ( ( TYPE, int ) ) ;
53
extern void decl_func_type PROTO_S ( ( IDENTIFIER, TYPE, int ) ) ;
54
extern TYPE find_func_type PROTO_S ( ( TYPE ) ) ;
55
extern TYPE redecl_func_type PROTO_S ( ( IDENTIFIER, TYPE, TYPE, int, int ) ) ;
56
extern EXP apply_func_id PROTO_S ( ( IDENTIFIER, QUALIFIER, GRAPH, LIST ( EXP ) ) ) ;
57
extern LIST ( EXP ) convert_args PROTO_S ( ( LIST ( EXP ) ) ) ;
58
extern EXP make_func_exp PROTO_S ( ( EXP, LIST ( EXP ), int ) ) ;
59
extern EXP check_inline PROTO_S ( ( IDENTIFIER, LIST ( EXP ), TYPE ) ) ;
60
extern TYPE check_main PROTO_S ( ( TYPE, HASHID ) ) ;
61
extern void recheck_main PROTO_S ( ( IDENTIFIER ) ) ;
62
extern int pass_complex_type PROTO_S ( ( TYPE ) ) ;
63
extern unsigned min_no_args PROTO_S ( ( TYPE ) ) ;
64
extern void func_type_defn PROTO_S ( ( int ) ) ;
65
extern ERROR check_param_type PROTO_S ( ( IDENTIFIER, TYPE ) ) ;
66
extern TYPE check_ret_type PROTO_S ( ( TYPE, ERROR *, int ) ) ;
67
extern int check_func_dargs PROTO_S ( ( TYPE, int, int ) ) ;
68
extern void object_type PROTO_S ( ( TYPE, unsigned ) ) ;
69
 
70
 
71
/*
72
    FUNCTION VARIABLES
73
 
74
    These variables are used to store information about the current
75
    function definition.
76
*/
77
 
78
extern IDENTIFIER crt_func_id ;
79
extern TYPE crt_func_return ;
80
extern int crt_func_complex ;
81
extern IDENTIFIER main_function ;
82
 
83
 
84
/*
85
    FUNCTION TYPES
86
 
87
    The various kinds of functions are given by combinations of the
88
    following values, which are stored in the ellipsis field of the
89
    corresponding function type.  In C++ the only possibilities are
90
    FUNC_NONE and FUNC_ELLIPSIS indicating whether or not the function
91
    is declared with ellipsis; the fact that these have the values 0 and
92
    1 is used.  In C non-prototype functions introduce other kinds of
93
    function:
94
 
95
	FUNC_NO_PARAMS		no type information,
96
	FUNC_WEAK_PARAMS	weak prototype or non-prototype definition,
97
	FUNC_WEAK_ARGS		implicit weak prototype.
98
 
99
    During type construction the following values are used:
100
 
101
	FUNC_NO_PARAMS		no type information,
102
	FUNC_PARAMS		non-prototype definition,
103
	FUNC_WEAK		weak prototype.
104
*/
105
 
106
#define FUNC_NONE		0
107
#define FUNC_ELLIPSIS		1
108
#define FUNC_WEAK		2
109
#define FUNC_PARAMS		4
110
#define FUNC_NO_PARAMS		8
111
#define FUNC_WEAK_PARAMS	( FUNC_WEAK | FUNC_PARAMS )
112
#define FUNC_WEAK_ARGS		( FUNC_WEAK )
113
#define FUNC_VAR_PARAMS		( FUNC_ELLIPSIS | FUNC_NO_PARAMS )
114
#define FUNC_NON_PROTO		( FUNC_WEAK | FUNC_PARAMS | FUNC_NO_PARAMS )
115
 
116
 
117
#endif