Bug Summary

File:build/gcc/vec.h
Warning:line 815, column 10
Called C++ object pointer is null

Annotated Source Code

Press '?' to see keyboard shortcuts

clang -cc1 -cc1 -triple x86_64-unknown-linux-gnu -analyze -disable-free -disable-llvm-verifier -discard-value-names -main-file-name semantics.c -analyzer-store=region -analyzer-opt-analyze-nested-blocks -analyzer-checker=core -analyzer-checker=apiModeling -analyzer-checker=unix -analyzer-checker=deadcode -analyzer-checker=cplusplus -analyzer-checker=security.insecureAPI.UncheckedReturn -analyzer-checker=security.insecureAPI.getpw -analyzer-checker=security.insecureAPI.gets -analyzer-checker=security.insecureAPI.mktemp -analyzer-checker=security.insecureAPI.mkstemp -analyzer-checker=security.insecureAPI.vfork -analyzer-checker=nullability.NullPassedToNonnull -analyzer-checker=nullability.NullReturnedFromNonnull -analyzer-output plist -w -setup-static-analyzer -analyzer-config-compatibility-mode=true -mrelocation-model static -mframe-pointer=none -fmath-errno -fno-rounding-math -mconstructor-aliases -munwind-tables -target-cpu x86-64 -fno-split-dwarf-inlining -debugger-tuning=gdb -resource-dir /usr/lib64/clang/11.0.0 -D IN_GCC_FRONTEND -D IN_GCC -D HAVE_CONFIG_H -I . -I cp -I /home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc -I /home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp -I /home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/../include -I /home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/../libcpp/include -I /home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/../libcody -I /home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/../libdecnumber -I /home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/../libdecnumber/bid -I ../libdecnumber -I /home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/../libbacktrace -internal-isystem /usr/bin/../lib64/gcc/x86_64-suse-linux/10/../../../../include/c++/10 -internal-isystem /usr/bin/../lib64/gcc/x86_64-suse-linux/10/../../../../include/c++/10/x86_64-suse-linux -internal-isystem /usr/bin/../lib64/gcc/x86_64-suse-linux/10/../../../../include/c++/10/backward -internal-isystem /usr/local/include -internal-isystem /usr/lib64/clang/11.0.0/include -internal-externc-isystem /include -internal-externc-isystem /usr/include -O2 -Wno-narrowing -Wwrite-strings -Wno-error=format-diag -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings -fdeprecated-macro -fdebug-compilation-dir /home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/objdir/gcc -ferror-limit 19 -fno-rtti -fgnuc-version=4.2.1 -vectorize-loops -vectorize-slp -analyzer-output=plist-html -analyzer-config silence-checkers=core.NullDereference -faddrsig -o /home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/objdir/clang-static-analyzer/2021-01-16-135054-17580-1/report-31w0e7.plist -x c++ /home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c

/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c

1/* Perform the semantic phase of parsing, i.e., the process of
2 building tree structure, checking semantic consistency, and
3 building RTL. These routines are used both during actual parsing
4 and during the instantiation of template functions.
5
6 Copyright (C) 1998-2021 Free Software Foundation, Inc.
7 Written by Mark Mitchell (mmitchell@usa.net) based on code found
8 formerly in parse.y and pt.c.
9
10 This file is part of GCC.
11
12 GCC is free software; you can redistribute it and/or modify it
13 under the terms of the GNU General Public License as published by
14 the Free Software Foundation; either version 3, or (at your option)
15 any later version.
16
17 GCC is distributed in the hope that it will be useful, but
18 WITHOUT ANY WARRANTY; without even the implied warranty of
19 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20 General Public License for more details.
21
22You should have received a copy of the GNU General Public License
23along with GCC; see the file COPYING3. If not see
24<http://www.gnu.org/licenses/>. */
25
26#include "config.h"
27#include "system.h"
28#include "coretypes.h"
29#include "target.h"
30#include "bitmap.h"
31#include "cp-tree.h"
32#include "stringpool.h"
33#include "cgraph.h"
34#include "stmt.h"
35#include "varasm.h"
36#include "stor-layout.h"
37#include "c-family/c-objc.h"
38#include "tree-inline.h"
39#include "intl.h"
40#include "tree-iterator.h"
41#include "omp-general.h"
42#include "convert.h"
43#include "stringpool.h"
44#include "attribs.h"
45#include "gomp-constants.h"
46#include "predict.h"
47#include "memmodel.h"
48
49/* There routines provide a modular interface to perform many parsing
50 operations. They may therefore be used during actual parsing, or
51 during template instantiation, which may be regarded as a
52 degenerate form of parsing. */
53
54static tree maybe_convert_cond (tree);
55static tree finalize_nrv_r (tree *, int *, void *);
56static tree capture_decltype (tree);
57
58/* Used for OpenMP non-static data member privatization. */
59
60static hash_map<tree, tree> *omp_private_member_map;
61static vec<tree> omp_private_member_vec;
62static bool omp_private_member_ignore_next;
63
64
65/* Deferred Access Checking Overview
66 ---------------------------------
67
68 Most C++ expressions and declarations require access checking
69 to be performed during parsing. However, in several cases,
70 this has to be treated differently.
71
72 For member declarations, access checking has to be deferred
73 until more information about the declaration is known. For
74 example:
75
76 class A {
77 typedef int X;
78 public:
79 X f();
80 };
81
82 A::X A::f();
83 A::X g();
84
85 When we are parsing the function return type `A::X', we don't
86 really know if this is allowed until we parse the function name.
87
88 Furthermore, some contexts require that access checking is
89 never performed at all. These include class heads, and template
90 instantiations.
91
92 Typical use of access checking functions is described here:
93
94 1. When we enter a context that requires certain access checking
95 mode, the function `push_deferring_access_checks' is called with
96 DEFERRING argument specifying the desired mode. Access checking
97 may be performed immediately (dk_no_deferred), deferred
98 (dk_deferred), or not performed (dk_no_check).
99
100 2. When a declaration such as a type, or a variable, is encountered,
101 the function `perform_or_defer_access_check' is called. It
102 maintains a vector of all deferred checks.
103
104 3. The global `current_class_type' or `current_function_decl' is then
105 setup by the parser. `enforce_access' relies on these information
106 to check access.
107
108 4. Upon exiting the context mentioned in step 1,
109 `perform_deferred_access_checks' is called to check all declaration
110 stored in the vector. `pop_deferring_access_checks' is then
111 called to restore the previous access checking mode.
112
113 In case of parsing error, we simply call `pop_deferring_access_checks'
114 without `perform_deferred_access_checks'. */
115
116struct GTY(()) deferred_access {
117 /* A vector representing name-lookups for which we have deferred
118 checking access controls. We cannot check the accessibility of
119 names used in a decl-specifier-seq until we know what is being
120 declared because code like:
121
122 class A {
123 class B {};
124 B* f();
125 }
126
127 A::B* A::f() { return 0; }
128
129 is valid, even though `A::B' is not generally accessible. */
130 vec<deferred_access_check, va_gc> *deferred_access_checks;
131
132 /* The current mode of access checks. */
133 enum deferring_kind deferring_access_checks_kind;
134};
135
136/* Data for deferred access checking. */
137static GTY(()) vec<deferred_access, va_gc> *deferred_access_stack;
138static GTY(()) unsigned deferred_access_no_check;
139
140/* Save the current deferred access states and start deferred
141 access checking iff DEFER_P is true. */
142
143void
144push_deferring_access_checks (deferring_kind deferring)
145{
146 /* For context like template instantiation, access checking
147 disabling applies to all nested context. */
148 if (deferred_access_no_check || deferring == dk_no_check)
149 deferred_access_no_check++;
150 else
151 {
152 deferred_access e = {NULL__null, deferring};
153 vec_safe_push (deferred_access_stack, e);
154 }
155}
156
157/* Save the current deferred access states and start deferred access
158 checking, continuing the set of deferred checks in CHECKS. */
159
160void
161reopen_deferring_access_checks (vec<deferred_access_check, va_gc> * checks)
162{
163 push_deferring_access_checks (dk_deferred);
164 if (!deferred_access_no_check)
165 deferred_access_stack->last().deferred_access_checks = checks;
166}
167
168/* Resume deferring access checks again after we stopped doing
169 this previously. */
170
171void
172resume_deferring_access_checks (void)
173{
174 if (!deferred_access_no_check)
175 deferred_access_stack->last().deferring_access_checks_kind = dk_deferred;
176}
177
178/* Stop deferring access checks. */
179
180void
181stop_deferring_access_checks (void)
182{
183 if (!deferred_access_no_check)
184 deferred_access_stack->last().deferring_access_checks_kind = dk_no_deferred;
185}
186
187/* Discard the current deferred access checks and restore the
188 previous states. */
189
190void
191pop_deferring_access_checks (void)
192{
193 if (deferred_access_no_check)
194 deferred_access_no_check--;
195 else
196 deferred_access_stack->pop ();
197}
198
199/* Returns a TREE_LIST representing the deferred checks.
200 The TREE_PURPOSE of each node is the type through which the
201 access occurred; the TREE_VALUE is the declaration named.
202 */
203
204vec<deferred_access_check, va_gc> *
205get_deferred_access_checks (void)
206{
207 if (deferred_access_no_check)
208 return NULL__null;
209 else
210 return (deferred_access_stack->last().deferred_access_checks);
211}
212
213/* Take current deferred checks and combine with the
214 previous states if we also defer checks previously.
215 Otherwise perform checks now. */
216
217void
218pop_to_parent_deferring_access_checks (void)
219{
220 if (deferred_access_no_check)
221 deferred_access_no_check--;
222 else
223 {
224 vec<deferred_access_check, va_gc> *checks;
225 deferred_access *ptr;
226
227 checks = (deferred_access_stack->last ().deferred_access_checks);
228
229 deferred_access_stack->pop ();
230 ptr = &deferred_access_stack->last ();
231 if (ptr->deferring_access_checks_kind == dk_no_deferred)
232 {
233 /* Check access. */
234 perform_access_checks (checks, tf_warning_or_error);
235 }
236 else
237 {
238 /* Merge with parent. */
239 int i, j;
240 deferred_access_check *chk, *probe;
241
242 FOR_EACH_VEC_SAFE_ELT (checks, i, chk)for (i = 0; vec_safe_iterate ((checks), (i), &(chk)); ++(
i))
243 {
244 FOR_EACH_VEC_SAFE_ELT (ptr->deferred_access_checks, j, probe)for (j = 0; vec_safe_iterate ((ptr->deferred_access_checks
), (j), &(probe)); ++(j))
245 {
246 if (probe->binfo == chk->binfo &&
247 probe->decl == chk->decl &&
248 probe->diag_decl == chk->diag_decl)
249 goto found;
250 }
251 /* Insert into parent's checks. */
252 vec_safe_push (ptr->deferred_access_checks, *chk);
253 found:;
254 }
255 }
256 }
257}
258
259/* If the current scope isn't allowed to access DECL along
260 BASETYPE_PATH, give an error, or if we're parsing a function or class
261 template, defer the access check to be performed at instantiation time.
262 The most derived class in BASETYPE_PATH is the one used to qualify DECL.
263 DIAG_DECL is the declaration to use in the error diagnostic. */
264
265static bool
266enforce_access (tree basetype_path, tree decl, tree diag_decl,
267 tsubst_flags_t complain, access_failure_info *afi = NULL__null)
268{
269 gcc_assert (TREE_CODE (basetype_path) == TREE_BINFO)((void)(!(((enum tree_code) (basetype_path)->base.code) ==
TREE_BINFO) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 269, __FUNCTION__), 0 : 0))
;
270
271 if (flag_new_inheriting_ctorsglobal_options.x_flag_new_inheriting_ctors
272 && DECL_INHERITED_CTOR (decl)((((enum tree_code) (decl)->base.code) == FUNCTION_DECL ||
(((enum tree_code) (decl)->base.code) == TEMPLATE_DECL &&
((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((decl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 272, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((decl
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 272, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->base
.code) == FUNCTION_DECL)) && ((tree_check (((((enum tree_code
) (decl)->base.code) == TEMPLATE_DECL ? ((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((decl
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 272, __FUNCTION__, (TEMPLATE_DECL))))))))->result : decl
)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 272, __FUNCTION__, (FUNCTION_DECL)))->decl_with_vis.cxx_constructor
) ? __extension__ ({ struct lang_decl *lt = ((contains_struct_check
(((((enum tree_code) (decl)->base.code) == TEMPLATE_DECL ?
((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((decl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 272, __FUNCTION__, (TEMPLATE_DECL))))))))->result : decl
)), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 272, __FUNCTION__))->decl_common.lang_specific); if (!((
(enum tree_code) (decl)->base.code) == FUNCTION_DECL || ((
(enum tree_code) (decl)->base.code) == TEMPLATE_DECL &&
((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((decl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 272, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((decl
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 272, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->base
.code) == FUNCTION_DECL)) || lt->u.base.selector != lds_fn
) lang_check_failed ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 272, __FUNCTION__); &lt->u.fn; })->context : (tree
) __null)
)
273 {
274 /* 7.3.3/18: The additional constructors are accessible if they would be
275 accessible when used to construct an object of the corresponding base
276 class. */
277 decl = strip_inheriting_ctors (decl);
278 basetype_path = lookup_base (basetype_path, DECL_CONTEXT (decl)((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 278, __FUNCTION__))->decl_minimal.context)
,
279 ba_any, NULL__null, complain);
280 }
281
282 tree cs = current_scope ();
283 if (processing_template_declscope_chain->x_processing_template_decl
284 && (CLASS_TYPE_P (cs)(((((enum tree_code) (cs)->base.code)) == RECORD_TYPE || (
((enum tree_code) (cs)->base.code)) == UNION_TYPE) &&
((tree_class_check ((cs), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 284, __FUNCTION__))->type_common.lang_flag_5))
|| TREE_CODE (cs)((enum tree_code) (cs)->base.code) == FUNCTION_DECL))
285 if (tree template_info = get_template_info (cs))
286 {
287 /* When parsing a function or class template, we in general need to
288 defer access checks until template instantiation time, since a friend
289 declaration may grant access only to a particular specialization of
290 the template. */
291
292 if (accessible_p (basetype_path, decl, /*consider_local_p=*/true))
293 /* But if the member is deemed accessible at parse time, then we can
294 assume it'll be accessible at instantiation time. */
295 return true;
296
297 /* Access of a dependent decl should be rechecked after tsubst'ing
298 into the user of the decl, rather than explicitly deferring the
299 check here. */
300 gcc_assert (!uses_template_parms (decl))((void)(!(!uses_template_parms (decl)) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 300, __FUNCTION__), 0 : 0))
;
301 if (TREE_CODE (decl)((enum tree_code) (decl)->base.code) == FIELD_DECL)
302 gcc_assert (!uses_template_parms (DECL_CONTEXT (decl)))((void)(!(!uses_template_parms (((contains_struct_check ((decl
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 302, __FUNCTION__))->decl_minimal.context))) ? fancy_abort
("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 302, __FUNCTION__), 0 : 0))
;
303
304 /* Defer this access check until instantiation time. */
305 deferred_access_check access_check;
306 access_check.binfo = basetype_path;
307 access_check.decl = decl;
308 access_check.diag_decl = diag_decl;
309 access_check.loc = input_location;
310 vec_safe_push (TI_DEFERRED_ACCESS_CHECKS (template_info)((struct tree_template_info*)(tree_check ((template_info), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 310, __FUNCTION__, (TEMPLATE_INFO))))->deferred_access_checks
, access_check);
311 return true;
312 }
313
314 if (!accessible_p (basetype_path, decl, /*consider_local_p=*/true))
315 {
316 if (flag_new_inheriting_ctorsglobal_options.x_flag_new_inheriting_ctors)
317 diag_decl = strip_inheriting_ctors (diag_decl);
318 if (complain & tf_error)
319 complain_about_access (decl, diag_decl, true);
320 if (afi)
321 afi->record_access_failure (basetype_path, decl, diag_decl);
322 return false;
323 }
324
325 return true;
326}
327
328/* Perform the access checks in CHECKS. The TREE_PURPOSE of each node
329 is the BINFO indicating the qualifying scope used to access the
330 DECL node stored in the TREE_VALUE of the node. If CHECKS is empty
331 or we aren't in SFINAE context or all the checks succeed return TRUE,
332 otherwise FALSE. */
333
334bool
335perform_access_checks (vec<deferred_access_check, va_gc> *checks,
336 tsubst_flags_t complain)
337{
338 int i;
339 deferred_access_check *chk;
340 location_t loc = input_location;
341 bool ok = true;
342
343 if (!checks)
344 return true;
345
346 FOR_EACH_VEC_SAFE_ELT (checks, i, chk)for (i = 0; vec_safe_iterate ((checks), (i), &(chk)); ++(
i))
347 {
348 input_location = chk->loc;
349 ok &= enforce_access (chk->binfo, chk->decl, chk->diag_decl, complain);
350 }
351
352 input_location = loc;
353 return (complain & tf_error) ? true : ok;
354}
355
356/* Perform the deferred access checks.
357
358 After performing the checks, we still have to keep the list
359 `deferred_access_stack->deferred_access_checks' since we may want
360 to check access for them again later in a different context.
361 For example:
362
363 class A {
364 typedef int X;
365 static X a;
366 };
367 A::X A::a, x; // No error for `A::a', error for `x'
368
369 We have to perform deferred access of `A::X', first with `A::a',
370 next with `x'. Return value like perform_access_checks above. */
371
372bool
373perform_deferred_access_checks (tsubst_flags_t complain)
374{
375 return perform_access_checks (get_deferred_access_checks (), complain);
376}
377
378/* Defer checking the accessibility of DECL, when looked up in
379 BINFO. DIAG_DECL is the declaration to use to print diagnostics.
380 Return value like perform_access_checks above.
381 If non-NULL, report failures to AFI. */
382
383bool
384perform_or_defer_access_check (tree binfo, tree decl, tree diag_decl,
385 tsubst_flags_t complain,
386 access_failure_info *afi)
387{
388 int i;
389 deferred_access *ptr;
390 deferred_access_check *chk;
391
392 /* Exit if we are in a context that no access checking is performed. */
393 if (deferred_access_no_check)
394 return true;
395
396 gcc_assert (TREE_CODE (binfo) == TREE_BINFO)((void)(!(((enum tree_code) (binfo)->base.code) == TREE_BINFO
) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 396, __FUNCTION__), 0 : 0))
;
397
398 ptr = &deferred_access_stack->last ();
399
400 /* If we are not supposed to defer access checks, just check now. */
401 if (ptr->deferring_access_checks_kind == dk_no_deferred)
402 {
403 bool ok = enforce_access (binfo, decl, diag_decl, complain, afi);
404 return (complain & tf_error) ? true : ok;
405 }
406
407 /* See if we are already going to perform this check. */
408 FOR_EACH_VEC_SAFE_ELT (ptr->deferred_access_checks, i, chk)for (i = 0; vec_safe_iterate ((ptr->deferred_access_checks
), (i), &(chk)); ++(i))
409 {
410 if (chk->decl == decl && chk->binfo == binfo &&
411 chk->diag_decl == diag_decl)
412 {
413 return true;
414 }
415 }
416 /* If not, record the check. */
417 deferred_access_check new_access = {binfo, decl, diag_decl, input_location};
418 vec_safe_push (ptr->deferred_access_checks, new_access);
419
420 return true;
421}
422
423/* Returns nonzero if the current statement is a full expression,
424 i.e. temporaries created during that statement should be destroyed
425 at the end of the statement. */
426
427int
428stmts_are_full_exprs_p (void)
429{
430 return current_stmt_tree ()->stmts_are_full_exprs_p;
431}
432
433/* T is a statement. Add it to the statement-tree. This is the C++
434 version. The C/ObjC frontends have a slightly different version of
435 this function. */
436
437tree
438add_stmt (tree t)
439{
440 enum tree_code code = TREE_CODE (t)((enum tree_code) (t)->base.code);
441
442 if (EXPR_P (t)((tree_code_type[(int) (((enum tree_code) (t)->base.code))
]) >= tcc_reference && (tree_code_type[(int) (((enum
tree_code) (t)->base.code))]) <= tcc_expression)
&& code != LABEL_EXPR)
443 {
444 if (!EXPR_HAS_LOCATION (t)(((IS_ADHOC_LOC (((((t)) && ((tree_code_type[(int) ((
(enum tree_code) ((t))->base.code))]) >= tcc_reference &&
(tree_code_type[(int) (((enum tree_code) ((t))->base.code
))]) <= tcc_expression)) ? (t)->exp.locus : ((location_t
) 0)))) ? get_location_from_adhoc_loc (line_table, ((((t)) &&
((tree_code_type[(int) (((enum tree_code) ((t))->base.code
))]) >= tcc_reference && (tree_code_type[(int) (((
enum tree_code) ((t))->base.code))]) <= tcc_expression)
) ? (t)->exp.locus : ((location_t) 0))) : (((((t)) &&
((tree_code_type[(int) (((enum tree_code) ((t))->base.code
))]) >= tcc_reference && (tree_code_type[(int) (((
enum tree_code) ((t))->base.code))]) <= tcc_expression)
) ? (t)->exp.locus : ((location_t) 0)))) != ((location_t) 0
))
)
445 SET_EXPR_LOCATION (t, input_location)(expr_check (((t)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 445, __FUNCTION__))->exp.locus = (input_location)
;
446
447 /* When we expand a statement-tree, we must know whether or not the
448 statements are full-expressions. We record that fact here. */
449 if (STATEMENT_CODE_P (TREE_CODE (t))statement_code_p[(int) (((enum tree_code) (t)->base.code))
]
)
450 STMT_IS_FULL_EXPR_P (t)((tree_not_check2 (((t)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 450, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_1)
= stmts_are_full_exprs_p ();
451 }
452
453 if (code == LABEL_EXPR || code == CASE_LABEL_EXPR)
454 STATEMENT_LIST_HAS_LABEL (cur_stmt_list)((tree_not_check2 (((tree_check ((((current_stmt_tree ()->
x_cur_stmt_list)->last ())), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 454, __FUNCTION__, (STATEMENT_LIST)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 454, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_3)
= 1;
455
456 /* Add T to the statement-tree. Non-side-effect statements need to be
457 recorded during statement expressions. */
458 gcc_checking_assert (!stmt_list_stack->is_empty ())((void)(!(!(current_stmt_tree ()->x_cur_stmt_list)->is_empty
()) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 458, __FUNCTION__), 0 : 0))
;
459 append_to_statement_list_force (t, &cur_stmt_list((current_stmt_tree ()->x_cur_stmt_list)->last ()));
460
461 return t;
462}
463
464/* Returns the stmt_tree to which statements are currently being added. */
465
466stmt_tree
467current_stmt_tree (void)
468{
469 return (cfun(cfun + 0)
470 ? &cfun(cfun + 0)->language->base.x_stmt_tree
471 : &scope_chain->x_stmt_tree);
472}
473
474/* If statements are full expressions, wrap STMT in a CLEANUP_POINT_EXPR. */
475
476static tree
477maybe_cleanup_point_expr (tree expr)
478{
479 if (!processing_template_declscope_chain->x_processing_template_decl && stmts_are_full_exprs_p ())
480 expr = fold_build_cleanup_point_expr (TREE_TYPE (expr)((contains_struct_check ((expr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 480, __FUNCTION__))->typed.type)
, expr);
481 return expr;
482}
483
484/* Like maybe_cleanup_point_expr except have the type of the new expression be
485 void so we don't need to create a temporary variable to hold the inner
486 expression. The reason why we do this is because the original type might be
487 an aggregate and we cannot create a temporary variable for that type. */
488
489tree
490maybe_cleanup_point_expr_void (tree expr)
491{
492 if (!processing_template_declscope_chain->x_processing_template_decl && stmts_are_full_exprs_p ())
493 expr = fold_build_cleanup_point_expr (void_type_nodeglobal_trees[TI_VOID_TYPE], expr);
494 return expr;
495}
496
497
498
499/* Create a declaration statement for the declaration given by the DECL. */
500
501void
502add_decl_expr (tree decl)
503{
504 tree r = build_stmt (DECL_SOURCE_LOCATION (decl)((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 504, __FUNCTION__))->decl_minimal.locus)
, DECL_EXPR, decl);
505 if (DECL_INITIAL (decl)((contains_struct_check ((decl), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 505, __FUNCTION__))->decl_common.initial)
506 || (DECL_SIZE (decl)((contains_struct_check ((decl), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 506, __FUNCTION__))->decl_common.size)
&& TREE_SIDE_EFFECTS (DECL_SIZE (decl))((non_type_check ((((contains_struct_check ((decl), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 506, __FUNCTION__))->decl_common.size)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 506, __FUNCTION__))->base.side_effects_flag)
))
507 r = maybe_cleanup_point_expr_void (r);
508 add_stmt (r);
509}
510
511/* Finish a scope. */
512
513tree
514do_poplevel (tree stmt_list)
515{
516 tree block = NULL__null;
517
518 if (stmts_are_full_exprs_p ())
519 block = poplevel (kept_level_p (), 1, 0);
520
521 stmt_list = pop_stmt_list (stmt_list);
522
523 if (!processing_template_declscope_chain->x_processing_template_decl)
524 {
525 stmt_list = c_build_bind_expr (input_location, block, stmt_list);
526 /* ??? See c_end_compound_stmt re statement expressions. */
527 }
528
529 return stmt_list;
530}
531
532/* Begin a new scope. */
533
534static tree
535do_pushlevel (scope_kind sk)
536{
537 tree ret = push_stmt_list ();
538 if (stmts_are_full_exprs_p ())
539 begin_scope (sk, NULL__null);
540 return ret;
541}
542
543/* Queue a cleanup. CLEANUP is an expression/statement to be executed
544 when the current scope is exited. EH_ONLY is true when this is not
545 meant to apply to normal control flow transfer. */
546
547void
548push_cleanup (tree decl, tree cleanup, bool eh_only)
549{
550 tree stmt = build_stmt (input_location, CLEANUP_STMT, NULL__null, cleanup, decl);
551 CLEANUP_EH_ONLY (stmt)((stmt)->base.static_flag) = eh_only;
552 add_stmt (stmt);
553 CLEANUP_BODY (stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 553, __FUNCTION__, (CLEANUP_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 553, __FUNCTION__)))))
= push_stmt_list ();
554}
555
556/* Simple infinite loop tracking for -Wreturn-type. We keep a stack of all
557 the current loops, represented by 'NULL_TREE' if we've seen a possible
558 exit, and 'error_mark_node' if not. This is currently used only to
559 suppress the warning about a function with no return statements, and
560 therefore we don't bother noting returns as possible exits. We also
561 don't bother with gotos. */
562
563static void
564begin_maybe_infinite_loop (tree cond)
565{
566 /* Only track this while parsing a function, not during instantiation. */
567 if (!cfun(cfun + 0) || (DECL_TEMPLATE_INSTANTIATION (current_function_decl)((((contains_struct_check ((current_function_decl), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 567, __FUNCTION__))->decl_common.lang_specific)->u.base
.use_template) & 1)
2
Assuming the condition is false
3
Assuming the condition is false
568 && !processing_template_declscope_chain->x_processing_template_decl))
569 return;
570 bool maybe_infinite = true;
571 if (cond)
4
Assuming 'cond' is null
5
Taking false branch
572 {
573 cond = fold_non_dependent_expr (cond);
574 maybe_infinite = integer_nonzerop (cond);
575 }
576 vec_safe_push (cp_function_chain((cfun + 0)->language)->infinite_loops,
7
Passing value via 1st parameter 'v'
8
Calling 'vec_safe_push<tree_node *, va_gc>'
577 maybe_infinite
5.1
'maybe_infinite' is true
5.1
'maybe_infinite' is true
? error_mark_nodeglobal_trees[TI_ERROR_MARK] : NULL_TREE(tree) __null)
;
6
'?' condition is true
578
579}
580
581/* A break is a possible exit for the current loop. */
582
583void
584break_maybe_infinite_loop (void)
585{
586 if (!cfun(cfun + 0))
587 return;
588 cp_function_chain((cfun + 0)->language)->infinite_loops->last() = NULL_TREE(tree) __null;
589}
590
591/* If we reach the end of the loop without seeing a possible exit, we have
592 an infinite loop. */
593
594static void
595end_maybe_infinite_loop (tree cond)
596{
597 if (!cfun(cfun + 0) || (DECL_TEMPLATE_INSTANTIATION (current_function_decl)((((contains_struct_check ((current_function_decl), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 597, __FUNCTION__))->decl_common.lang_specific)->u.base
.use_template) & 1)
598 && !processing_template_declscope_chain->x_processing_template_decl))
599 return;
600 tree current = cp_function_chain((cfun + 0)->language)->infinite_loops->pop();
601 if (current != NULL_TREE(tree) __null)
602 {
603 cond = fold_non_dependent_expr (cond);
604 if (integer_nonzerop (cond))
605 current_function_infinite_loop((cfun + 0)->language)->infinite_loop = 1;
606 }
607}
608
609
610/* Begin a conditional that might contain a declaration. When generating
611 normal code, we want the declaration to appear before the statement
612 containing the conditional. When generating template code, we want the
613 conditional to be rendered as the raw DECL_EXPR. */
614
615static void
616begin_cond (tree *cond_p)
617{
618 if (processing_template_declscope_chain->x_processing_template_decl)
619 *cond_p = push_stmt_list ();
620}
621
622/* Finish such a conditional. */
623
624static void
625finish_cond (tree *cond_p, tree expr)
626{
627 if (processing_template_declscope_chain->x_processing_template_decl)
628 {
629 tree cond = pop_stmt_list (*cond_p);
630
631 if (expr == NULL_TREE(tree) __null)
632 /* Empty condition in 'for'. */
633 gcc_assert (empty_expr_stmt_p (cond))((void)(!(empty_expr_stmt_p (cond)) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 633, __FUNCTION__), 0 : 0))
;
634 else if (check_for_bare_parameter_packs (expr))
635 expr = error_mark_nodeglobal_trees[TI_ERROR_MARK];
636 else if (!empty_expr_stmt_p (cond))
637 expr = build2 (COMPOUND_EXPR, TREE_TYPE (expr)((contains_struct_check ((expr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 637, __FUNCTION__))->typed.type)
, cond, expr);
638 }
639 *cond_p = expr;
640}
641
642/* If *COND_P specifies a conditional with a declaration, transform the
643 loop such that
644 while (A x = 42) { }
645 for (; A x = 42;) { }
646 becomes
647 while (true) { A x = 42; if (!x) break; }
648 for (;;) { A x = 42; if (!x) break; }
649 The statement list for BODY will be empty if the conditional did
650 not declare anything. */
651
652static void
653simplify_loop_decl_cond (tree *cond_p, tree body)
654{
655 tree cond, if_stmt;
656
657 if (!TREE_SIDE_EFFECTS (body)((non_type_check ((body), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 657, __FUNCTION__))->base.side_effects_flag)
)
658 return;
659
660 cond = *cond_p;
661 *cond_p = boolean_true_nodeglobal_trees[TI_BOOLEAN_TRUE];
662
663 if_stmt = begin_if_stmt ();
664 cond = cp_build_unary_op (TRUTH_NOT_EXPR, cond, false, tf_warning_or_error);
665 finish_if_stmt_cond (cond, if_stmt);
666 finish_break_stmt ();
667 finish_then_clause (if_stmt);
668 finish_if_stmt (if_stmt);
669}
670
671/* Finish a goto-statement. */
672
673tree
674finish_goto_stmt (tree destination)
675{
676 if (identifier_p (destination))
677 destination = lookup_label (destination);
678
679 /* We warn about unused labels with -Wunused. That means we have to
680 mark the used labels as used. */
681 if (TREE_CODE (destination)((enum tree_code) (destination)->base.code) == LABEL_DECL)
682 TREE_USED (destination)((destination)->base.used_flag) = 1;
683 else
684 {
685 destination = mark_rvalue_use (destination);
686 if (!processing_template_declscope_chain->x_processing_template_decl)
687 {
688 destination = cp_convert (ptr_type_nodeglobal_trees[TI_PTR_TYPE], destination,
689 tf_warning_or_error);
690 if (error_operand_p (destination)((destination) == global_trees[TI_ERROR_MARK] || ((destination
) && ((contains_struct_check (((destination)), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 690, __FUNCTION__))->typed.type) == global_trees[TI_ERROR_MARK
]))
)
691 return NULL_TREE(tree) __null;
692 destination
693 = fold_build_cleanup_point_expr (TREE_TYPE (destination)((contains_struct_check ((destination), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 693, __FUNCTION__))->typed.type)
,
694 destination);
695 }
696 }
697
698 check_goto (destination);
699
700 add_stmt (build_predict_expr (PRED_GOTO, NOT_TAKEN));
701 return add_stmt (build_stmt (input_location, GOTO_EXPR, destination));
702}
703
704/* COND is the condition-expression for an if, while, etc.,
705 statement. Convert it to a boolean value, if appropriate.
706 In addition, verify sequence points if -Wsequence-point is enabled. */
707
708static tree
709maybe_convert_cond (tree cond)
710{
711 /* Empty conditions remain empty. */
712 if (!cond)
713 return NULL_TREE(tree) __null;
714
715 /* Wait until we instantiate templates before doing conversion. */
716 if (type_dependent_expression_p (cond))
717 return cond;
718
719 if (warn_sequence_pointglobal_options.x_warn_sequence_point && !processing_template_declscope_chain->x_processing_template_decl)
720 verify_sequence_points (cond);
721
722 /* Do the conversion. */
723 cond = convert_from_reference (cond);
724
725 if (TREE_CODE (cond)((enum tree_code) (cond)->base.code) == MODIFY_EXPR
726 && !TREE_NO_WARNING (cond)((cond)->base.nowarning_flag)
727 && warn_parenthesesglobal_options.x_warn_parentheses
728 && warning_at (cp_expr_loc_or_input_loc (cond),
729 OPT_Wparentheses, "suggest parentheses around "
730 "assignment used as truth value"))
731 TREE_NO_WARNING (cond)((cond)->base.nowarning_flag) = 1;
732
733 return condition_conversion (cond);
734}
735
736/* Finish an expression-statement, whose EXPRESSION is as indicated. */
737
738tree
739finish_expr_stmt (tree expr)
740{
741 tree r = NULL_TREE(tree) __null;
742 location_t loc = EXPR_LOCATION (expr)((((expr)) && ((tree_code_type[(int) (((enum tree_code
) ((expr))->base.code))]) >= tcc_reference && (
tree_code_type[(int) (((enum tree_code) ((expr))->base.code
))]) <= tcc_expression)) ? (expr)->exp.locus : ((location_t
) 0))
;
743
744 if (expr != NULL_TREE(tree) __null)
745 {
746 /* If we ran into a problem, make sure we complained. */
747 gcc_assert (expr != error_mark_node || seen_error ())((void)(!(expr != global_trees[TI_ERROR_MARK] || seen_error (
)) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 747, __FUNCTION__), 0 : 0))
;
748
749 if (!processing_template_declscope_chain->x_processing_template_decl)
750 {
751 if (warn_sequence_pointglobal_options.x_warn_sequence_point)
752 verify_sequence_points (expr);
753 expr = convert_to_void (expr, ICV_STATEMENT, tf_warning_or_error);
754 }
755 else if (!type_dependent_expression_p (expr))
756 convert_to_void (build_non_dependent_expr (expr), ICV_STATEMENT,
757 tf_warning_or_error);
758
759 if (check_for_bare_parameter_packs (expr))
760 expr = error_mark_nodeglobal_trees[TI_ERROR_MARK];
761
762 /* Simplification of inner statement expressions, compound exprs,
763 etc can result in us already having an EXPR_STMT. */
764 if (TREE_CODE (expr)((enum tree_code) (expr)->base.code) != CLEANUP_POINT_EXPR)
765 {
766 if (TREE_CODE (expr)((enum tree_code) (expr)->base.code) != EXPR_STMT)
767 expr = build_stmt (loc, EXPR_STMT, expr);
768 expr = maybe_cleanup_point_expr_void (expr);
769 }
770
771 r = add_stmt (expr);
772 }
773
774 return r;
775}
776
777
778/* Begin an if-statement. Returns a newly created IF_STMT if
779 appropriate. */
780
781tree
782begin_if_stmt (void)
783{
784 tree r, scope;
785 scope = do_pushlevel (sk_cond);
786 r = build_stmt (input_location, IF_STMT, NULL_TREE(tree) __null,
787 NULL_TREE(tree) __null, NULL_TREE(tree) __null, scope);
788 current_binding_level(*((cfun + 0) && ((cfun + 0)->language) &&
((cfun + 0)->language)->bindings ? &((cfun + 0)->
language)->bindings : &scope_chain->bindings))
->this_entity = r;
789 begin_cond (&IF_COND (r)(*((const_cast<tree*> (tree_operand_check (((tree_check
((r), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 789, __FUNCTION__, (IF_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 789, __FUNCTION__)))))
);
790 return r;
791}
792
793/* Returns true if FN, a CALL_EXPR, is a call to
794 std::is_constant_evaluated or __builtin_is_constant_evaluated. */
795
796static bool
797is_std_constant_evaluated_p (tree fn)
798{
799 /* std::is_constant_evaluated takes no arguments. */
800 if (call_expr_nargs (fn)(((int)((unsigned long) (*tree_int_cst_elt_check (((tree_class_check
((fn), (tcc_vl_exp), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 800, __FUNCTION__))->exp.operands[0]), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 800, __FUNCTION__)))) - 3)
!= 0)
801 return false;
802
803 tree fndecl = cp_get_callee_fndecl_nofold (fn);
804 if (fndecl == NULL_TREE(tree) __null)
805 return false;
806
807 if (fndecl_built_in_p (fndecl, CP_BUILT_IN_IS_CONSTANT_EVALUATED,
808 BUILT_IN_FRONTEND))
809 return true;
810
811 if (!decl_in_std_namespace_p (fndecl))
812 return false;
813
814 tree name = DECL_NAME (fndecl)((contains_struct_check ((fndecl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 814, __FUNCTION__))->decl_minimal.name)
;
815 return name && id_equal (name, "is_constant_evaluated");
816}
817
818/* Process the COND of an if-statement, which may be given by
819 IF_STMT. */
820
821tree
822finish_if_stmt_cond (tree cond, tree if_stmt)
823{
824 cond = maybe_convert_cond (cond);
825 if (IF_STMT_CONSTEXPR_P (if_stmt)((tree_not_check2 (((tree_check ((if_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 825, __FUNCTION__, (IF_STMT)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 825, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_0)
826 && !type_dependent_expression_p (cond)
827 && require_constant_expression (cond)
828 && !instantiation_dependent_expression_p (cond)
829 /* Wait until instantiation time, since only then COND has been
830 converted to bool. */
831 && TYPE_MAIN_VARIANT (TREE_TYPE (cond))((tree_class_check ((((contains_struct_check ((cond), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 831, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 831, __FUNCTION__))->type_common.main_variant)
== boolean_type_nodeglobal_trees[TI_BOOLEAN_TYPE])
832 {
833 /* if constexpr (std::is_constant_evaluated()) is always true,
834 so give the user a clue. */
835 if (warn_tautological_compareglobal_options.x_warn_tautological_compare)
836 {
837 tree t = cond;
838 if (TREE_CODE (t)((enum tree_code) (t)->base.code) == CLEANUP_POINT_EXPR)
839 t = TREE_OPERAND (t, 0)(*((const_cast<tree*> (tree_operand_check ((t), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 839, __FUNCTION__)))))
;
840 if (TREE_CODE (t)((enum tree_code) (t)->base.code) == CALL_EXPR
841 && is_std_constant_evaluated_p (t))
842 warning_at (EXPR_LOCATION (cond)((((cond)) && ((tree_code_type[(int) (((enum tree_code
) ((cond))->base.code))]) >= tcc_reference && (
tree_code_type[(int) (((enum tree_code) ((cond))->base.code
))]) <= tcc_expression)) ? (cond)->exp.locus : ((location_t
) 0))
, OPT_Wtautological_compare,
843 "%qs always evaluates to true in %<if constexpr%>",
844 "std::is_constant_evaluated");
845 }
846
847 cond = instantiate_non_dependent_expr (cond);
848 cond = cxx_constant_value (cond, NULL_TREE(tree) __null);
849 }
850 finish_cond (&IF_COND (if_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((if_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 850, __FUNCTION__, (IF_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 850, __FUNCTION__)))))
, cond);
851 add_stmt (if_stmt);
852 THEN_CLAUSE (if_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((if_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 852, __FUNCTION__, (IF_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 852, __FUNCTION__)))))
= push_stmt_list ();
853 return cond;
854}
855
856/* Finish the then-clause of an if-statement, which may be given by
857 IF_STMT. */
858
859tree
860finish_then_clause (tree if_stmt)
861{
862 THEN_CLAUSE (if_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((if_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 862, __FUNCTION__, (IF_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 862, __FUNCTION__)))))
= pop_stmt_list (THEN_CLAUSE (if_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((if_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 862, __FUNCTION__, (IF_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 862, __FUNCTION__)))))
);
863 return if_stmt;
864}
865
866/* Begin the else-clause of an if-statement. */
867
868void
869begin_else_clause (tree if_stmt)
870{
871 ELSE_CLAUSE (if_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((if_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 871, __FUNCTION__, (IF_STMT)))), (2), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 871, __FUNCTION__)))))
= push_stmt_list ();
872}
873
874/* Finish the else-clause of an if-statement, which may be given by
875 IF_STMT. */
876
877void
878finish_else_clause (tree if_stmt)
879{
880 ELSE_CLAUSE (if_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((if_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 880, __FUNCTION__, (IF_STMT)))), (2), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 880, __FUNCTION__)))))
= pop_stmt_list (ELSE_CLAUSE (if_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((if_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 880, __FUNCTION__, (IF_STMT)))), (2), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 880, __FUNCTION__)))))
);
881}
882
883/* Callback for cp_walk_tree to mark all {VAR,PARM}_DECLs in a tree as
884 read. */
885
886static tree
887maybe_mark_exp_read_r (tree *tp, int *, void *)
888{
889 tree t = *tp;
890 if (VAR_P (t)(((enum tree_code) (t)->base.code) == VAR_DECL) || TREE_CODE (t)((enum tree_code) (t)->base.code) == PARM_DECL)
891 mark_exp_read (t);
892 return NULL_TREE(tree) __null;
893}
894
895/* Finish an if-statement. */
896
897void
898finish_if_stmt (tree if_stmt)
899{
900 tree scope = IF_SCOPE (if_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((if_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 900, __FUNCTION__, (IF_STMT)))), (3), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 900, __FUNCTION__)))))
;
901 IF_SCOPE (if_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((if_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 901, __FUNCTION__, (IF_STMT)))), (3), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 901, __FUNCTION__)))))
= NULL__null;
902 if (IF_STMT_CONSTEXPR_P (if_stmt)((tree_not_check2 (((tree_check ((if_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 902, __FUNCTION__, (IF_STMT)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 902, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_0)
)
903 {
904 /* Prevent various -Wunused warnings. We might not instantiate
905 either of these branches, so we would not mark the variables
906 used in that branch as read. */
907 cp_walk_tree_without_duplicates (&THEN_CLAUSE (if_stmt),walk_tree_without_duplicates_1 (&(*((const_cast<tree*>
(tree_operand_check (((tree_check ((if_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 907, __FUNCTION__, (IF_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 907, __FUNCTION__))))), maybe_mark_exp_read_r, __null, cp_walk_subtrees
)
908 maybe_mark_exp_read_r, NULL)walk_tree_without_duplicates_1 (&(*((const_cast<tree*>
(tree_operand_check (((tree_check ((if_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 907, __FUNCTION__, (IF_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 907, __FUNCTION__))))), maybe_mark_exp_read_r, __null, cp_walk_subtrees
)
;
909 cp_walk_tree_without_duplicates (&ELSE_CLAUSE (if_stmt),walk_tree_without_duplicates_1 (&(*((const_cast<tree*>
(tree_operand_check (((tree_check ((if_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 909, __FUNCTION__, (IF_STMT)))), (2), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 909, __FUNCTION__))))), maybe_mark_exp_read_r, __null, cp_walk_subtrees
)
910 maybe_mark_exp_read_r, NULL)walk_tree_without_duplicates_1 (&(*((const_cast<tree*>
(tree_operand_check (((tree_check ((if_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 909, __FUNCTION__, (IF_STMT)))), (2), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 909, __FUNCTION__))))), maybe_mark_exp_read_r, __null, cp_walk_subtrees
)
;
911 }
912 add_stmt (do_poplevel (scope));
913}
914
915/* Begin a while-statement. Returns a newly created WHILE_STMT if
916 appropriate. */
917
918tree
919begin_while_stmt (void)
920{
921 tree r;
922 r = build_stmt (input_location, WHILE_STMT, NULL_TREE(tree) __null, NULL_TREE(tree) __null);
923 add_stmt (r);
924 WHILE_BODY (r)(*((const_cast<tree*> (tree_operand_check (((tree_check
((r), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 924, __FUNCTION__, (WHILE_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 924, __FUNCTION__)))))
= do_pushlevel (sk_block);
925 begin_cond (&WHILE_COND (r)(*((const_cast<tree*> (tree_operand_check (((tree_check
((r), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 925, __FUNCTION__, (WHILE_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 925, __FUNCTION__)))))
);
926 return r;
927}
928
929/* Process the COND of a while-statement, which may be given by
930 WHILE_STMT. */
931
932void
933finish_while_stmt_cond (tree cond, tree while_stmt, bool ivdep,
934 unsigned short unroll)
935{
936 cond = maybe_convert_cond (cond);
937 finish_cond (&WHILE_COND (while_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((while_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 937, __FUNCTION__, (WHILE_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 937, __FUNCTION__)))))
, cond);
938 begin_maybe_infinite_loop (cond);
939 if (ivdep && cond != error_mark_nodeglobal_trees[TI_ERROR_MARK])
940 WHILE_COND (while_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((while_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 940, __FUNCTION__, (WHILE_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 940, __FUNCTION__)))))
= build3 (ANNOTATE_EXPR,
941 TREE_TYPE (WHILE_COND (while_stmt))((contains_struct_check (((*((const_cast<tree*> (tree_operand_check
(((tree_check ((while_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 941, __FUNCTION__, (WHILE_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 941, __FUNCTION__)))))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 941, __FUNCTION__))->typed.type)
,
942 WHILE_COND (while_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((while_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 942, __FUNCTION__, (WHILE_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 942, __FUNCTION__)))))
,
943 build_int_cst (integer_type_nodeinteger_types[itk_int],
944 annot_expr_ivdep_kind),
945 integer_zero_nodeglobal_trees[TI_INTEGER_ZERO]);
946 if (unroll && cond != error_mark_nodeglobal_trees[TI_ERROR_MARK])
947 WHILE_COND (while_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((while_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 947, __FUNCTION__, (WHILE_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 947, __FUNCTION__)))))
= build3 (ANNOTATE_EXPR,
948 TREE_TYPE (WHILE_COND (while_stmt))((contains_struct_check (((*((const_cast<tree*> (tree_operand_check
(((tree_check ((while_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 948, __FUNCTION__, (WHILE_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 948, __FUNCTION__)))))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 948, __FUNCTION__))->typed.type)
,
949 WHILE_COND (while_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((while_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 949, __FUNCTION__, (WHILE_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 949, __FUNCTION__)))))
,
950 build_int_cst (integer_type_nodeinteger_types[itk_int],
951 annot_expr_unroll_kind),
952 build_int_cst (integer_type_nodeinteger_types[itk_int],
953 unroll));
954 simplify_loop_decl_cond (&WHILE_COND (while_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((while_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 954, __FUNCTION__, (WHILE_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 954, __FUNCTION__)))))
, WHILE_BODY (while_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((while_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 954, __FUNCTION__, (WHILE_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 954, __FUNCTION__)))))
);
955}
956
957/* Finish a while-statement, which may be given by WHILE_STMT. */
958
959void
960finish_while_stmt (tree while_stmt)
961{
962 end_maybe_infinite_loop (boolean_true_nodeglobal_trees[TI_BOOLEAN_TRUE]);
963 WHILE_BODY (while_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((while_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 963, __FUNCTION__, (WHILE_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 963, __FUNCTION__)))))
= do_poplevel (WHILE_BODY (while_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((while_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 963, __FUNCTION__, (WHILE_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 963, __FUNCTION__)))))
);
964}
965
966/* Begin a do-statement. Returns a newly created DO_STMT if
967 appropriate. */
968
969tree
970begin_do_stmt (void)
971{
972 tree r = build_stmt (input_location, DO_STMT, NULL_TREE(tree) __null, NULL_TREE(tree) __null);
973 begin_maybe_infinite_loop (boolean_true_nodeglobal_trees[TI_BOOLEAN_TRUE]);
974 add_stmt (r);
975 DO_BODY (r)(*((const_cast<tree*> (tree_operand_check (((tree_check
((r), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 975, __FUNCTION__, (DO_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 975, __FUNCTION__)))))
= push_stmt_list ();
976 return r;
977}
978
979/* Finish the body of a do-statement, which may be given by DO_STMT. */
980
981void
982finish_do_body (tree do_stmt)
983{
984 tree body = DO_BODY (do_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((do_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 984, __FUNCTION__, (DO_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 984, __FUNCTION__)))))
= pop_stmt_list (DO_BODY (do_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((do_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 984, __FUNCTION__, (DO_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 984, __FUNCTION__)))))
);
985
986 if (TREE_CODE (body)((enum tree_code) (body)->base.code) == STATEMENT_LIST && STATEMENT_LIST_TAIL (body)((tree_check ((body), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 986, __FUNCTION__, (STATEMENT_LIST)))->stmt_list.tail)
)
987 body = STATEMENT_LIST_TAIL (body)((tree_check ((body), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 987, __FUNCTION__, (STATEMENT_LIST)))->stmt_list.tail)
->stmt;
988
989 if (IS_EMPTY_STMT (body)(((enum tree_code) (body)->base.code) == NOP_EXPR &&
(((enum tree_code) (((contains_struct_check ((body), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 989, __FUNCTION__))->typed.type))->base.code) == VOID_TYPE
) && integer_zerop ((*((const_cast<tree*> (tree_operand_check
((body), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 989, __FUNCTION__)))))))
)
990 warning (OPT_Wempty_body,
991 "suggest explicit braces around empty body in %<do%> statement");
992}
993
994/* Finish a do-statement, which may be given by DO_STMT, and whose
995 COND is as indicated. */
996
997void
998finish_do_stmt (tree cond, tree do_stmt, bool ivdep, unsigned short unroll)
999{
1000 cond = maybe_convert_cond (cond);
1001 end_maybe_infinite_loop (cond);
1002 if (ivdep && cond != error_mark_nodeglobal_trees[TI_ERROR_MARK])
1003 cond = build3 (ANNOTATE_EXPR, TREE_TYPE (cond)((contains_struct_check ((cond), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1003, __FUNCTION__))->typed.type)
, cond,
1004 build_int_cst (integer_type_nodeinteger_types[itk_int], annot_expr_ivdep_kind),
1005 integer_zero_nodeglobal_trees[TI_INTEGER_ZERO]);
1006 if (unroll && cond != error_mark_nodeglobal_trees[TI_ERROR_MARK])
1007 cond = build3 (ANNOTATE_EXPR, TREE_TYPE (cond)((contains_struct_check ((cond), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1007, __FUNCTION__))->typed.type)
, cond,
1008 build_int_cst (integer_type_nodeinteger_types[itk_int], annot_expr_unroll_kind),
1009 build_int_cst (integer_type_nodeinteger_types[itk_int], unroll));
1010 DO_COND (do_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((do_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1010, __FUNCTION__, (DO_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1010, __FUNCTION__)))))
= cond;
1011}
1012
1013/* Finish a return-statement. The EXPRESSION returned, if any, is as
1014 indicated. */
1015
1016tree
1017finish_return_stmt (tree expr)
1018{
1019 tree r;
1020 bool no_warning;
1021
1022 expr = check_return_expr (expr, &no_warning);
1023
1024 if (error_operand_p (expr)((expr) == global_trees[TI_ERROR_MARK] || ((expr) && (
(contains_struct_check (((expr)), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1024, __FUNCTION__))->typed.type) == global_trees[TI_ERROR_MARK
]))
1025 || (flag_openmpglobal_options.x_flag_openmp && !check_omp_return ()))
1026 {
1027 /* Suppress -Wreturn-type for this function. */
1028 if (warn_return_typeglobal_options.x_warn_return_type)
1029 TREE_NO_WARNING (current_function_decl)((current_function_decl)->base.nowarning_flag) = true;
1030 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
1031 }
1032
1033 if (!processing_template_declscope_chain->x_processing_template_decl)
1034 {
1035 if (warn_sequence_pointglobal_options.x_warn_sequence_point)
1036 verify_sequence_points (expr);
1037
1038 if (DECL_DESTRUCTOR_P (current_function_decl)((tree_check (((((enum tree_code) (current_function_decl)->
base.code) == TEMPLATE_DECL ? ((struct tree_template_decl *)(
const_cast<union tree_node *> ((((tree_check ((current_function_decl
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1038, __FUNCTION__, (TEMPLATE_DECL))))))))->result : current_function_decl
)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1038, __FUNCTION__, (FUNCTION_DECL)))->decl_with_vis.cxx_destructor
)
1039 || (DECL_CONSTRUCTOR_P (current_function_decl)((tree_check (((((enum tree_code) (current_function_decl)->
base.code) == TEMPLATE_DECL ? ((struct tree_template_decl *)(
const_cast<union tree_node *> ((((tree_check ((current_function_decl
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1039, __FUNCTION__, (TEMPLATE_DECL))))))))->result : current_function_decl
)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1039, __FUNCTION__, (FUNCTION_DECL)))->decl_with_vis.cxx_constructor
)
1040 && targetm.cxx.cdtor_returns_this ()))
1041 {
1042 /* Similarly, all destructors must run destructors for
1043 base-classes before returning. So, all returns in a
1044 destructor get sent to the DTOR_LABEL; finish_function emits
1045 code to return a value there. */
1046 return finish_goto_stmt (cdtor_label((cfun + 0)->language)->x_cdtor_label);
1047 }
1048 }
1049
1050 r = build_stmt (input_location, RETURN_EXPR, expr);
1051 TREE_NO_WARNING (r)((r)->base.nowarning_flag) |= no_warning;
1052 r = maybe_cleanup_point_expr_void (r);
1053 r = add_stmt (r);
1054
1055 return r;
1056}
1057
1058/* Begin the scope of a for-statement or a range-for-statement.
1059 Both the returned trees are to be used in a call to
1060 begin_for_stmt or begin_range_for_stmt. */
1061
1062tree
1063begin_for_scope (tree *init)
1064{
1065 tree scope = do_pushlevel (sk_for);
1066
1067 if (processing_template_declscope_chain->x_processing_template_decl)
1068 *init = push_stmt_list ();
1069 else
1070 *init = NULL_TREE(tree) __null;
1071
1072 return scope;
1073}
1074
1075/* Begin a for-statement. Returns a new FOR_STMT.
1076 SCOPE and INIT should be the return of begin_for_scope,
1077 or both NULL_TREE */
1078
1079tree
1080begin_for_stmt (tree scope, tree init)
1081{
1082 tree r;
1083
1084 r = build_stmt (input_location, FOR_STMT, NULL_TREE(tree) __null, NULL_TREE(tree) __null,
1085 NULL_TREE(tree) __null, NULL_TREE(tree) __null, NULL_TREE(tree) __null);
1086
1087 if (scope == NULL_TREE(tree) __null)
1088 {
1089 gcc_assert (!init)((void)(!(!init) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1089, __FUNCTION__), 0 : 0))
;
1090 scope = begin_for_scope (&init);
1091 }
1092
1093 FOR_INIT_STMT (r)(*((const_cast<tree*> (tree_operand_check (((tree_check
((r), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1093, __FUNCTION__, (FOR_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1093, __FUNCTION__)))))
= init;
1094 FOR_SCOPE (r)(*((const_cast<tree*> (tree_operand_check (((tree_check
((r), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1094, __FUNCTION__, (FOR_STMT)))), (4), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1094, __FUNCTION__)))))
= scope;
1095
1096 return r;
1097}
1098
1099/* Finish the init-statement of a for-statement, which may be
1100 given by FOR_STMT. */
1101
1102void
1103finish_init_stmt (tree for_stmt)
1104{
1105 if (processing_template_declscope_chain->x_processing_template_decl)
1106 FOR_INIT_STMT (for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1106, __FUNCTION__, (FOR_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1106, __FUNCTION__)))))
= pop_stmt_list (FOR_INIT_STMT (for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1106, __FUNCTION__, (FOR_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1106, __FUNCTION__)))))
);
1107 add_stmt (for_stmt);
1108 FOR_BODY (for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1108, __FUNCTION__, (FOR_STMT)))), (3), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1108, __FUNCTION__)))))
= do_pushlevel (sk_block);
1109 begin_cond (&FOR_COND (for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1109, __FUNCTION__, (FOR_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1109, __FUNCTION__)))))
);
1110}
1111
1112/* Finish the COND of a for-statement, which may be given by
1113 FOR_STMT. */
1114
1115void
1116finish_for_cond (tree cond, tree for_stmt, bool ivdep, unsigned short unroll)
1117{
1118 cond = maybe_convert_cond (cond);
1119 finish_cond (&FOR_COND (for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1119, __FUNCTION__, (FOR_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1119, __FUNCTION__)))))
, cond);
1120 begin_maybe_infinite_loop (cond);
1121 if (ivdep && cond != error_mark_nodeglobal_trees[TI_ERROR_MARK])
1122 FOR_COND (for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1122, __FUNCTION__, (FOR_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1122, __FUNCTION__)))))
= build3 (ANNOTATE_EXPR,
1123 TREE_TYPE (FOR_COND (for_stmt))((contains_struct_check (((*((const_cast<tree*> (tree_operand_check
(((tree_check ((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1123, __FUNCTION__, (FOR_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1123, __FUNCTION__)))))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1123, __FUNCTION__))->typed.type)
,
1124 FOR_COND (for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1124, __FUNCTION__, (FOR_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1124, __FUNCTION__)))))
,
1125 build_int_cst (integer_type_nodeinteger_types[itk_int],
1126 annot_expr_ivdep_kind),
1127 integer_zero_nodeglobal_trees[TI_INTEGER_ZERO]);
1128 if (unroll && cond != error_mark_nodeglobal_trees[TI_ERROR_MARK])
1129 FOR_COND (for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1129, __FUNCTION__, (FOR_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1129, __FUNCTION__)))))
= build3 (ANNOTATE_EXPR,
1130 TREE_TYPE (FOR_COND (for_stmt))((contains_struct_check (((*((const_cast<tree*> (tree_operand_check
(((tree_check ((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1130, __FUNCTION__, (FOR_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1130, __FUNCTION__)))))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1130, __FUNCTION__))->typed.type)
,
1131 FOR_COND (for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1131, __FUNCTION__, (FOR_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1131, __FUNCTION__)))))
,
1132 build_int_cst (integer_type_nodeinteger_types[itk_int],
1133 annot_expr_unroll_kind),
1134 build_int_cst (integer_type_nodeinteger_types[itk_int],
1135 unroll));
1136 simplify_loop_decl_cond (&FOR_COND (for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1136, __FUNCTION__, (FOR_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1136, __FUNCTION__)))))
, FOR_BODY (for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1136, __FUNCTION__, (FOR_STMT)))), (3), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1136, __FUNCTION__)))))
);
1137}
1138
1139/* Finish the increment-EXPRESSION in a for-statement, which may be
1140 given by FOR_STMT. */
1141
1142void
1143finish_for_expr (tree expr, tree for_stmt)
1144{
1145 if (!expr)
1146 return;
1147 /* If EXPR is an overloaded function, issue an error; there is no
1148 context available to use to perform overload resolution. */
1149 if (type_unknown_p (expr))
1150 {
1151 cxx_incomplete_type_error (expr, TREE_TYPE (expr)((contains_struct_check ((expr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1151, __FUNCTION__))->typed.type)
);
1152 expr = error_mark_nodeglobal_trees[TI_ERROR_MARK];
1153 }
1154 if (!processing_template_declscope_chain->x_processing_template_decl)
1155 {
1156 if (warn_sequence_pointglobal_options.x_warn_sequence_point)
1157 verify_sequence_points (expr);
1158 expr = convert_to_void (expr, ICV_THIRD_IN_FOR,
1159 tf_warning_or_error);
1160 }
1161 else if (!type_dependent_expression_p (expr))
1162 convert_to_void (build_non_dependent_expr (expr), ICV_THIRD_IN_FOR,
1163 tf_warning_or_error);
1164 expr = maybe_cleanup_point_expr_void (expr);
1165 if (check_for_bare_parameter_packs (expr))
1166 expr = error_mark_nodeglobal_trees[TI_ERROR_MARK];
1167 FOR_EXPR (for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1167, __FUNCTION__, (FOR_STMT)))), (2), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1167, __FUNCTION__)))))
= expr;
1168}
1169
1170/* Finish the body of a for-statement, which may be given by
1171 FOR_STMT. The increment-EXPR for the loop must be
1172 provided.
1173 It can also finish RANGE_FOR_STMT. */
1174
1175void
1176finish_for_stmt (tree for_stmt)
1177{
1178 end_maybe_infinite_loop (boolean_true_nodeglobal_trees[TI_BOOLEAN_TRUE]);
1179
1180 if (TREE_CODE (for_stmt)((enum tree_code) (for_stmt)->base.code) == RANGE_FOR_STMT)
1181 RANGE_FOR_BODY (for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1181, __FUNCTION__, (RANGE_FOR_STMT)))), (2), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1181, __FUNCTION__)))))
= do_poplevel (RANGE_FOR_BODY (for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1181, __FUNCTION__, (RANGE_FOR_STMT)))), (2), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1181, __FUNCTION__)))))
);
1182 else
1183 FOR_BODY (for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1183, __FUNCTION__, (FOR_STMT)))), (3), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1183, __FUNCTION__)))))
= do_poplevel (FOR_BODY (for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1183, __FUNCTION__, (FOR_STMT)))), (3), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1183, __FUNCTION__)))))
);
1184
1185 /* Pop the scope for the body of the loop. */
1186 tree *scope_ptr = (TREE_CODE (for_stmt)((enum tree_code) (for_stmt)->base.code) == RANGE_FOR_STMT
1187 ? &RANGE_FOR_SCOPE (for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1187, __FUNCTION__, (RANGE_FOR_STMT)))), (3), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1187, __FUNCTION__)))))
1188 : &FOR_SCOPE (for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1188, __FUNCTION__, (FOR_STMT)))), (4), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1188, __FUNCTION__)))))
);
1189 tree scope = *scope_ptr;
1190 *scope_ptr = NULL__null;
1191
1192 /* During parsing of the body, range for uses "__for_{range,begin,end} "
1193 decl names to make those unaccessible by code in the body.
1194 Change it to ones with underscore instead of space, so that it can
1195 be inspected in the debugger. */
1196 tree range_for_decl[3] = { NULL_TREE(tree) __null, NULL_TREE(tree) __null, NULL_TREE(tree) __null };
1197 gcc_assert (CPTI_FOR_BEGIN__IDENTIFIER == CPTI_FOR_RANGE__IDENTIFIER + 1((void)(!(CPTI_FOR_BEGIN__IDENTIFIER == CPTI_FOR_RANGE__IDENTIFIER
+ 1 && CPTI_FOR_END__IDENTIFIER == CPTI_FOR_RANGE__IDENTIFIER
+ 2 && CPTI_FOR_RANGE_IDENTIFIER == CPTI_FOR_RANGE__IDENTIFIER
+ 3 && CPTI_FOR_BEGIN_IDENTIFIER == CPTI_FOR_BEGIN__IDENTIFIER
+ 3 && CPTI_FOR_END_IDENTIFIER == CPTI_FOR_END__IDENTIFIER
+ 3) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1201, __FUNCTION__), 0 : 0))
1198 && CPTI_FOR_END__IDENTIFIER == CPTI_FOR_RANGE__IDENTIFIER + 2((void)(!(CPTI_FOR_BEGIN__IDENTIFIER == CPTI_FOR_RANGE__IDENTIFIER
+ 1 && CPTI_FOR_END__IDENTIFIER == CPTI_FOR_RANGE__IDENTIFIER
+ 2 && CPTI_FOR_RANGE_IDENTIFIER == CPTI_FOR_RANGE__IDENTIFIER
+ 3 && CPTI_FOR_BEGIN_IDENTIFIER == CPTI_FOR_BEGIN__IDENTIFIER
+ 3 && CPTI_FOR_END_IDENTIFIER == CPTI_FOR_END__IDENTIFIER
+ 3) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1201, __FUNCTION__), 0 : 0))
1199 && CPTI_FOR_RANGE_IDENTIFIER == CPTI_FOR_RANGE__IDENTIFIER + 3((void)(!(CPTI_FOR_BEGIN__IDENTIFIER == CPTI_FOR_RANGE__IDENTIFIER
+ 1 && CPTI_FOR_END__IDENTIFIER == CPTI_FOR_RANGE__IDENTIFIER
+ 2 && CPTI_FOR_RANGE_IDENTIFIER == CPTI_FOR_RANGE__IDENTIFIER
+ 3 && CPTI_FOR_BEGIN_IDENTIFIER == CPTI_FOR_BEGIN__IDENTIFIER
+ 3 && CPTI_FOR_END_IDENTIFIER == CPTI_FOR_END__IDENTIFIER
+ 3) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1201, __FUNCTION__), 0 : 0))
1200 && CPTI_FOR_BEGIN_IDENTIFIER == CPTI_FOR_BEGIN__IDENTIFIER + 3((void)(!(CPTI_FOR_BEGIN__IDENTIFIER == CPTI_FOR_RANGE__IDENTIFIER
+ 1 && CPTI_FOR_END__IDENTIFIER == CPTI_FOR_RANGE__IDENTIFIER
+ 2 && CPTI_FOR_RANGE_IDENTIFIER == CPTI_FOR_RANGE__IDENTIFIER
+ 3 && CPTI_FOR_BEGIN_IDENTIFIER == CPTI_FOR_BEGIN__IDENTIFIER
+ 3 && CPTI_FOR_END_IDENTIFIER == CPTI_FOR_END__IDENTIFIER
+ 3) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1201, __FUNCTION__), 0 : 0))
1201 && CPTI_FOR_END_IDENTIFIER == CPTI_FOR_END__IDENTIFIER + 3)((void)(!(CPTI_FOR_BEGIN__IDENTIFIER == CPTI_FOR_RANGE__IDENTIFIER
+ 1 && CPTI_FOR_END__IDENTIFIER == CPTI_FOR_RANGE__IDENTIFIER
+ 2 && CPTI_FOR_RANGE_IDENTIFIER == CPTI_FOR_RANGE__IDENTIFIER
+ 3 && CPTI_FOR_BEGIN_IDENTIFIER == CPTI_FOR_BEGIN__IDENTIFIER
+ 3 && CPTI_FOR_END_IDENTIFIER == CPTI_FOR_END__IDENTIFIER
+ 3) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1201, __FUNCTION__), 0 : 0))
;
1202 for (int i = 0; i < 3; i++)
1203 {
1204 tree id = cp_global_trees[CPTI_FOR_RANGE__IDENTIFIER + i];
1205 if (IDENTIFIER_BINDING (id)(((struct lang_identifier*)(tree_check ((id), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1205, __FUNCTION__, (IDENTIFIER_NODE))))->bindings)
1206 && IDENTIFIER_BINDING (id)(((struct lang_identifier*)(tree_check ((id), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1206, __FUNCTION__, (IDENTIFIER_NODE))))->bindings)
->scope == current_binding_level(*((cfun + 0) && ((cfun + 0)->language) &&
((cfun + 0)->language)->bindings ? &((cfun + 0)->
language)->bindings : &scope_chain->bindings))
)
1207 {
1208 range_for_decl[i] = IDENTIFIER_BINDING (id)(((struct lang_identifier*)(tree_check ((id), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1208, __FUNCTION__, (IDENTIFIER_NODE))))->bindings)
->value;
1209 gcc_assert (VAR_P (range_for_decl[i])((void)(!((((enum tree_code) (range_for_decl[i])->base.code
) == VAR_DECL) && ((contains_struct_check ((range_for_decl
[i]), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1210, __FUNCTION__))->decl_common.artificial_flag)) ? fancy_abort
("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1210, __FUNCTION__), 0 : 0))
1210 && DECL_ARTIFICIAL (range_for_decl[i]))((void)(!((((enum tree_code) (range_for_decl[i])->base.code
) == VAR_DECL) && ((contains_struct_check ((range_for_decl
[i]), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1210, __FUNCTION__))->decl_common.artificial_flag)) ? fancy_abort
("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1210, __FUNCTION__), 0 : 0))
;
1211 }
1212 }
1213
1214 add_stmt (do_poplevel (scope));
1215
1216 for (int i = 0; i < 3; i++)
1217 if (range_for_decl[i])
1218 DECL_NAME (range_for_decl[i])((contains_struct_check ((range_for_decl[i]), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1218, __FUNCTION__))->decl_minimal.name)
1219 = cp_global_trees[CPTI_FOR_RANGE_IDENTIFIER + i];
1220}
1221
1222/* Begin a range-for-statement. Returns a new RANGE_FOR_STMT.
1223 SCOPE and INIT should be the return of begin_for_scope,
1224 or both NULL_TREE .
1225 To finish it call finish_for_stmt(). */
1226
1227tree
1228begin_range_for_stmt (tree scope, tree init)
1229{
1230 begin_maybe_infinite_loop (boolean_false_nodeglobal_trees[TI_BOOLEAN_FALSE]);
1
Calling 'begin_maybe_infinite_loop'
1231
1232 tree r = build_stmt (input_location, RANGE_FOR_STMT, NULL_TREE(tree) __null, NULL_TREE(tree) __null,
1233 NULL_TREE(tree) __null, NULL_TREE(tree) __null, NULL_TREE(tree) __null, NULL_TREE(tree) __null);
1234
1235 if (scope == NULL_TREE(tree) __null)
1236 {
1237 gcc_assert (!init)((void)(!(!init) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1237, __FUNCTION__), 0 : 0))
;
1238 scope = begin_for_scope (&init);
1239 }
1240
1241 /* Since C++20, RANGE_FOR_STMTs can use the init tree, so save it. */
1242 RANGE_FOR_INIT_STMT (r)(*((const_cast<tree*> (tree_operand_check (((tree_check
((r), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1242, __FUNCTION__, (RANGE_FOR_STMT)))), (5), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1242, __FUNCTION__)))))
= init;
1243 RANGE_FOR_SCOPE (r)(*((const_cast<tree*> (tree_operand_check (((tree_check
((r), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1243, __FUNCTION__, (RANGE_FOR_STMT)))), (3), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1243, __FUNCTION__)))))
= scope;
1244
1245 return r;
1246}
1247
1248/* Finish the head of a range-based for statement, which may
1249 be given by RANGE_FOR_STMT. DECL must be the declaration
1250 and EXPR must be the loop expression. */
1251
1252void
1253finish_range_for_decl (tree range_for_stmt, tree decl, tree expr)
1254{
1255 if (processing_template_declscope_chain->x_processing_template_decl)
1256 RANGE_FOR_INIT_STMT (range_for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((range_for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1256, __FUNCTION__, (RANGE_FOR_STMT)))), (5), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1256, __FUNCTION__)))))
1257 = pop_stmt_list (RANGE_FOR_INIT_STMT (range_for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((range_for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1257, __FUNCTION__, (RANGE_FOR_STMT)))), (5), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1257, __FUNCTION__)))))
);
1258 RANGE_FOR_DECL (range_for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((range_for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1258, __FUNCTION__, (RANGE_FOR_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1258, __FUNCTION__)))))
= decl;
1259 RANGE_FOR_EXPR (range_for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((range_for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1259, __FUNCTION__, (RANGE_FOR_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1259, __FUNCTION__)))))
= expr;
1260 add_stmt (range_for_stmt);
1261 RANGE_FOR_BODY (range_for_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((range_for_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1261, __FUNCTION__, (RANGE_FOR_STMT)))), (2), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1261, __FUNCTION__)))))
= do_pushlevel (sk_block);
1262}
1263
1264/* Finish a break-statement. */
1265
1266tree
1267finish_break_stmt (void)
1268{
1269 /* In switch statements break is sometimes stylistically used after
1270 a return statement. This can lead to spurious warnings about
1271 control reaching the end of a non-void function when it is
1272 inlined. Note that we are calling block_may_fallthru with
1273 language specific tree nodes; this works because
1274 block_may_fallthru returns true when given something it does not
1275 understand. */
1276 if (!block_may_fallthru (cur_stmt_list((current_stmt_tree ()->x_cur_stmt_list)->last ())))
1277 return void_nodeglobal_trees[TI_VOID];
1278 note_break_stmt ();
1279 return add_stmt (build_stmt (input_location, BREAK_STMT));
1280}
1281
1282/* Finish a continue-statement. */
1283
1284tree
1285finish_continue_stmt (void)
1286{
1287 return add_stmt (build_stmt (input_location, CONTINUE_STMT));
1288}
1289
1290/* Begin a switch-statement. Returns a new SWITCH_STMT if
1291 appropriate. */
1292
1293tree
1294begin_switch_stmt (void)
1295{
1296 tree r, scope;
1297
1298 scope = do_pushlevel (sk_cond);
1299 r = build_stmt (input_location, SWITCH_STMT, NULL_TREE(tree) __null, NULL_TREE(tree) __null, NULL_TREE(tree) __null, scope);
1300
1301 begin_cond (&SWITCH_STMT_COND (r)(*((const_cast<tree*> (tree_operand_check (((tree_check
((r), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1301, __FUNCTION__, (SWITCH_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1301, __FUNCTION__)))))
);
1302
1303 return r;
1304}
1305
1306/* Finish the cond of a switch-statement. */
1307
1308void
1309finish_switch_cond (tree cond, tree switch_stmt)
1310{
1311 tree orig_type = NULL__null;
1312
1313 if (!processing_template_declscope_chain->x_processing_template_decl)
1314 {
1315 /* Convert the condition to an integer or enumeration type. */
1316 tree orig_cond = cond;
1317 cond = build_expr_type_conversion (WANT_INT1 | WANT_ENUM4, cond, true);
1318 if (cond == NULL_TREE(tree) __null)
1319 {
1320 error_at (cp_expr_loc_or_input_loc (orig_cond),
1321 "switch quantity not an integer");
1322 cond = error_mark_nodeglobal_trees[TI_ERROR_MARK];
1323 }
1324 /* We want unlowered type here to handle enum bit-fields. */
1325 orig_type = unlowered_expr_type (cond);
1326 if (TREE_CODE (orig_type)((enum tree_code) (orig_type)->base.code) != ENUMERAL_TYPE)
1327 orig_type = TREE_TYPE (cond)((contains_struct_check ((cond), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1327, __FUNCTION__))->typed.type)
;
1328 if (cond != error_mark_nodeglobal_trees[TI_ERROR_MARK])
1329 {
1330 /* [stmt.switch]
1331
1332 Integral promotions are performed. */
1333 cond = perform_integral_promotions (cond);
1334 cond = maybe_cleanup_point_expr (cond);
1335 }
1336 }
1337 if (check_for_bare_parameter_packs (cond))
1338 cond = error_mark_nodeglobal_trees[TI_ERROR_MARK];
1339 else if (!processing_template_declscope_chain->x_processing_template_decl && warn_sequence_pointglobal_options.x_warn_sequence_point)
1340 verify_sequence_points (cond);
1341
1342 finish_cond (&SWITCH_STMT_COND (switch_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((switch_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1342, __FUNCTION__, (SWITCH_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1342, __FUNCTION__)))))
, cond);
1343 SWITCH_STMT_TYPE (switch_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((switch_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1343, __FUNCTION__, (SWITCH_STMT)))), (2), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1343, __FUNCTION__)))))
= orig_type;
1344 add_stmt (switch_stmt);
1345 push_switch (switch_stmt);
1346 SWITCH_STMT_BODY (switch_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((switch_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1346, __FUNCTION__, (SWITCH_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1346, __FUNCTION__)))))
= push_stmt_list ();
1347}
1348
1349/* Finish the body of a switch-statement, which may be given by
1350 SWITCH_STMT. The COND to switch on is indicated. */
1351
1352void
1353finish_switch_stmt (tree switch_stmt)
1354{
1355 tree scope;
1356
1357 SWITCH_STMT_BODY (switch_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((switch_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1357, __FUNCTION__, (SWITCH_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1357, __FUNCTION__)))))
=
1358 pop_stmt_list (SWITCH_STMT_BODY (switch_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((switch_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1358, __FUNCTION__, (SWITCH_STMT)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1358, __FUNCTION__)))))
);
1359 pop_switch ();
1360
1361 scope = SWITCH_STMT_SCOPE (switch_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((switch_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1361, __FUNCTION__, (SWITCH_STMT)))), (3), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1361, __FUNCTION__)))))
;
1362 SWITCH_STMT_SCOPE (switch_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((switch_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1362, __FUNCTION__, (SWITCH_STMT)))), (3), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1362, __FUNCTION__)))))
= NULL__null;
1363 add_stmt (do_poplevel (scope));
1364}
1365
1366/* Begin a try-block. Returns a newly-created TRY_BLOCK if
1367 appropriate. */
1368
1369tree
1370begin_try_block (void)
1371{
1372 tree r = build_stmt (input_location, TRY_BLOCK, NULL_TREE(tree) __null, NULL_TREE(tree) __null);
1373 add_stmt (r);
1374 TRY_STMTS (r)(*((const_cast<tree*> (tree_operand_check (((tree_check
((r), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1374, __FUNCTION__, (TRY_BLOCK)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1374, __FUNCTION__)))))
= push_stmt_list ();
1375 return r;
1376}
1377
1378/* Likewise, for a function-try-block. The block returned in
1379 *COMPOUND_STMT is an artificial outer scope, containing the
1380 function-try-block. */
1381
1382tree
1383begin_function_try_block (tree *compound_stmt)
1384{
1385 tree r;
1386 /* This outer scope does not exist in the C++ standard, but we need
1387 a place to put __FUNCTION__ and similar variables. */
1388 *compound_stmt = begin_compound_stmt (0);
1389 r = begin_try_block ();
1390 FN_TRY_BLOCK_P (r)((tree_not_check2 (((tree_check ((r), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1390, __FUNCTION__, (TRY_BLOCK)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1390, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_3)
= 1;
1391 return r;
1392}
1393
1394/* Finish a try-block, which may be given by TRY_BLOCK. */
1395
1396void
1397finish_try_block (tree try_block)
1398{
1399 TRY_STMTS (try_block)(*((const_cast<tree*> (tree_operand_check (((tree_check
((try_block), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1399, __FUNCTION__, (TRY_BLOCK)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1399, __FUNCTION__)))))
= pop_stmt_list (TRY_STMTS (try_block)(*((const_cast<tree*> (tree_operand_check (((tree_check
((try_block), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1399, __FUNCTION__, (TRY_BLOCK)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1399, __FUNCTION__)))))
);
1400 TRY_HANDLERS (try_block)(*((const_cast<tree*> (tree_operand_check (((tree_check
((try_block), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1400, __FUNCTION__, (TRY_BLOCK)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1400, __FUNCTION__)))))
= push_stmt_list ();
1401}
1402
1403/* Finish the body of a cleanup try-block, which may be given by
1404 TRY_BLOCK. */
1405
1406void
1407finish_cleanup_try_block (tree try_block)
1408{
1409 TRY_STMTS (try_block)(*((const_cast<tree*> (tree_operand_check (((tree_check
((try_block), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1409, __FUNCTION__, (TRY_BLOCK)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1409, __FUNCTION__)))))
= pop_stmt_list (TRY_STMTS (try_block)(*((const_cast<tree*> (tree_operand_check (((tree_check
((try_block), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1409, __FUNCTION__, (TRY_BLOCK)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1409, __FUNCTION__)))))
);
1410}
1411
1412/* Finish an implicitly generated try-block, with a cleanup is given
1413 by CLEANUP. */
1414
1415void
1416finish_cleanup (tree cleanup, tree try_block)
1417{
1418 TRY_HANDLERS (try_block)(*((const_cast<tree*> (tree_operand_check (((tree_check
((try_block), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1418, __FUNCTION__, (TRY_BLOCK)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1418, __FUNCTION__)))))
= cleanup;
1419 CLEANUP_P (try_block)((tree_not_check2 (((tree_check ((try_block), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1419, __FUNCTION__, (TRY_BLOCK)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1419, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_0)
= 1;
1420}
1421
1422/* Likewise, for a function-try-block. */
1423
1424void
1425finish_function_try_block (tree try_block)
1426{
1427 finish_try_block (try_block);
1428 /* FIXME : something queer about CTOR_INITIALIZER somehow following
1429 the try block, but moving it inside. */
1430 in_function_try_handler((cfun + 0)->language)->x_in_function_try_handler = 1;
1431}
1432
1433/* Finish a handler-sequence for a try-block, which may be given by
1434 TRY_BLOCK. */
1435
1436void
1437finish_handler_sequence (tree try_block)
1438{
1439 TRY_HANDLERS (try_block)(*((const_cast<tree*> (tree_operand_check (((tree_check
((try_block), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1439, __FUNCTION__, (TRY_BLOCK)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1439, __FUNCTION__)))))
= pop_stmt_list (TRY_HANDLERS (try_block)(*((const_cast<tree*> (tree_operand_check (((tree_check
((try_block), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1439, __FUNCTION__, (TRY_BLOCK)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1439, __FUNCTION__)))))
);
1440 check_handlers (TRY_HANDLERS (try_block)(*((const_cast<tree*> (tree_operand_check (((tree_check
((try_block), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1440, __FUNCTION__, (TRY_BLOCK)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1440, __FUNCTION__)))))
);
1441}
1442
1443/* Finish the handler-seq for a function-try-block, given by
1444 TRY_BLOCK. COMPOUND_STMT is the outer block created by
1445 begin_function_try_block. */
1446
1447void
1448finish_function_handler_sequence (tree try_block, tree compound_stmt)
1449{
1450 in_function_try_handler((cfun + 0)->language)->x_in_function_try_handler = 0;
1451 finish_handler_sequence (try_block);
1452 finish_compound_stmt (compound_stmt);
1453}
1454
1455/* Begin a handler. Returns a HANDLER if appropriate. */
1456
1457tree
1458begin_handler (void)
1459{
1460 tree r;
1461
1462 r = build_stmt (input_location, HANDLER, NULL_TREE(tree) __null, NULL_TREE(tree) __null);
1463 add_stmt (r);
1464
1465 /* Create a binding level for the eh_info and the exception object
1466 cleanup. */
1467 HANDLER_BODY (r)(*((const_cast<tree*> (tree_operand_check (((tree_check
((r), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1467, __FUNCTION__, (HANDLER)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1467, __FUNCTION__)))))
= do_pushlevel (sk_catch);
1468
1469 return r;
1470}
1471
1472/* Finish the handler-parameters for a handler, which may be given by
1473 HANDLER. DECL is the declaration for the catch parameter, or NULL
1474 if this is a `catch (...)' clause. */
1475
1476void
1477finish_handler_parms (tree decl, tree handler)
1478{
1479 tree type = NULL_TREE(tree) __null;
1480 if (processing_template_declscope_chain->x_processing_template_decl)
1481 {
1482 if (decl)
1483 {
1484 decl = pushdecl (decl);
1485 decl = push_template_decl (decl);
1486 HANDLER_PARMS (handler)(*((const_cast<tree*> (tree_operand_check (((tree_check
((handler), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1486, __FUNCTION__, (HANDLER)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1486, __FUNCTION__)))))
= decl;
1487 type = TREE_TYPE (decl)((contains_struct_check ((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1487, __FUNCTION__))->typed.type)
;
1488 }
1489 }
1490 else
1491 {
1492 type = expand_start_catch_block (decl);
1493 if (warn_catch_valueglobal_options.x_warn_catch_value
1494 && type != NULL_TREE(tree) __null
1495 && type != error_mark_nodeglobal_trees[TI_ERROR_MARK]
1496 && !TYPE_REF_P (TREE_TYPE (decl))(((enum tree_code) (((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1496, __FUNCTION__))->typed.type))->base.code) == REFERENCE_TYPE
)
)
1497 {
1498 tree orig_type = TREE_TYPE (decl)((contains_struct_check ((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1498, __FUNCTION__))->typed.type)
;
1499 if (CLASS_TYPE_P (orig_type)(((((enum tree_code) (orig_type)->base.code)) == RECORD_TYPE
|| (((enum tree_code) (orig_type)->base.code)) == UNION_TYPE
) && ((tree_class_check ((orig_type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1499, __FUNCTION__))->type_common.lang_flag_5))
)
1500 {
1501 if (TYPE_POLYMORPHIC_P (orig_type)(((tree_not_check2 ((orig_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1501, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_2))
)
1502 warning_at (DECL_SOURCE_LOCATION (decl)((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1502, __FUNCTION__))->decl_minimal.locus)
,
1503 OPT_Wcatch_value_,
1504 "catching polymorphic type %q#T by value",
1505 orig_type);
1506 else if (warn_catch_valueglobal_options.x_warn_catch_value > 1)
1507 warning_at (DECL_SOURCE_LOCATION (decl)((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1507, __FUNCTION__))->decl_minimal.locus)
,
1508 OPT_Wcatch_value_,
1509 "catching type %q#T by value", orig_type);
1510 }
1511 else if (warn_catch_valueglobal_options.x_warn_catch_value > 2)
1512 warning_at (DECL_SOURCE_LOCATION (decl)((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1512, __FUNCTION__))->decl_minimal.locus)
,
1513 OPT_Wcatch_value_,
1514 "catching non-reference type %q#T", orig_type);
1515 }
1516 }
1517 HANDLER_TYPE (handler)((contains_struct_check (((tree_check ((handler), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1517, __FUNCTION__, (HANDLER)))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1517, __FUNCTION__))->typed.type)
= type;
1518}
1519
1520/* Finish a handler, which may be given by HANDLER. The BLOCKs are
1521 the return value from the matching call to finish_handler_parms. */
1522
1523void
1524finish_handler (tree handler)
1525{
1526 if (!processing_template_declscope_chain->x_processing_template_decl)
1527 expand_end_catch_block ();
1528 HANDLER_BODY (handler)(*((const_cast<tree*> (tree_operand_check (((tree_check
((handler), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1528, __FUNCTION__, (HANDLER)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1528, __FUNCTION__)))))
= do_poplevel (HANDLER_BODY (handler)(*((const_cast<tree*> (tree_operand_check (((tree_check
((handler), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1528, __FUNCTION__, (HANDLER)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1528, __FUNCTION__)))))
);
1529}
1530
1531/* Begin a compound statement. FLAGS contains some bits that control the
1532 behavior and context. If BCS_NO_SCOPE is set, the compound statement
1533 does not define a scope. If BCS_FN_BODY is set, this is the outermost
1534 block of a function. If BCS_TRY_BLOCK is set, this is the block
1535 created on behalf of a TRY statement. Returns a token to be passed to
1536 finish_compound_stmt. */
1537
1538tree
1539begin_compound_stmt (unsigned int flags)
1540{
1541 tree r;
1542
1543 if (flags & BCS_NO_SCOPE)
1544 {
1545 r = push_stmt_list ();
1546 STATEMENT_LIST_NO_SCOPE (r)((tree_not_check2 (((tree_check ((r), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1546, __FUNCTION__, (STATEMENT_LIST)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1546, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_0)
= 1;
1547
1548 /* Normally, we try hard to keep the BLOCK for a statement-expression.
1549 But, if it's a statement-expression with a scopeless block, there's
1550 nothing to keep, and we don't want to accidentally keep a block
1551 *inside* the scopeless block. */
1552 keep_next_level (false);
1553 }
1554 else
1555 {
1556 scope_kind sk = sk_block;
1557 if (flags & BCS_TRY_BLOCK)
1558 sk = sk_try;
1559 else if (flags & BCS_TRANSACTION)
1560 sk = sk_transaction;
1561 r = do_pushlevel (sk);
1562 }
1563
1564 /* When processing a template, we need to remember where the braces were,
1565 so that we can set up identical scopes when instantiating the template
1566 later. BIND_EXPR is a handy candidate for this.
1567 Note that do_poplevel won't create a BIND_EXPR itself here (and thus
1568 result in nested BIND_EXPRs), since we don't build BLOCK nodes when
1569 processing templates. */
1570 if (processing_template_declscope_chain->x_processing_template_decl)
1571 {
1572 r = build3 (BIND_EXPR, NULL__null, NULL__null, r, NULL__null);
1573 BIND_EXPR_TRY_BLOCK (r)((tree_not_check2 (((tree_check ((r), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1573, __FUNCTION__, (BIND_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1573, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_0)
= (flags & BCS_TRY_BLOCK) != 0;
1574 BIND_EXPR_BODY_BLOCK (r)((tree_not_check2 (((tree_check ((r), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1574, __FUNCTION__, (BIND_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1574, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_3)
= (flags & BCS_FN_BODY) != 0;
1575 TREE_SIDE_EFFECTS (r)((non_type_check ((r), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1575, __FUNCTION__))->base.side_effects_flag)
= 1;
1576 }
1577
1578 return r;
1579}
1580
1581/* Finish a compound-statement, which is given by STMT. */
1582
1583void
1584finish_compound_stmt (tree stmt)
1585{
1586 if (TREE_CODE (stmt)((enum tree_code) (stmt)->base.code) == BIND_EXPR)
1587 {
1588 tree body = do_poplevel (BIND_EXPR_BODY (stmt)((*((const_cast<tree*> (tree_operand_check (((tree_check
((stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1588, __FUNCTION__, (BIND_EXPR)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1588, __FUNCTION__))))))
);
1589 /* If the STATEMENT_LIST is empty and this BIND_EXPR isn't special,
1590 discard the BIND_EXPR so it can be merged with the containing
1591 STATEMENT_LIST. */
1592 if (TREE_CODE (body)((enum tree_code) (body)->base.code) == STATEMENT_LIST
1593 && STATEMENT_LIST_HEAD (body)((tree_check ((body), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1593, __FUNCTION__, (STATEMENT_LIST)))->stmt_list.head)
== NULL__null
1594 && !BIND_EXPR_BODY_BLOCK (stmt)((tree_not_check2 (((tree_check ((stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1594, __FUNCTION__, (BIND_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1594, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_3)
1595 && !BIND_EXPR_TRY_BLOCK (stmt)((tree_not_check2 (((tree_check ((stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1595, __FUNCTION__, (BIND_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1595, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_0)
)
1596 stmt = body;
1597 else
1598 BIND_EXPR_BODY (stmt)((*((const_cast<tree*> (tree_operand_check (((tree_check
((stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1598, __FUNCTION__, (BIND_EXPR)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1598, __FUNCTION__))))))
= body;
1599 }
1600 else if (STATEMENT_LIST_NO_SCOPE (stmt)((tree_not_check2 (((tree_check ((stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1600, __FUNCTION__, (STATEMENT_LIST)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1600, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_0)
)
1601 stmt = pop_stmt_list (stmt);
1602 else
1603 {
1604 /* Destroy any ObjC "super" receivers that may have been
1605 created. */
1606 objc_clear_super_receiver ();
1607
1608 stmt = do_poplevel (stmt);
1609 }
1610
1611 /* ??? See c_end_compound_stmt wrt statement expressions. */
1612 add_stmt (stmt);
1613}
1614
1615/* Finish an asm-statement, whose components are a STRING, some
1616 OUTPUT_OPERANDS, some INPUT_OPERANDS, some CLOBBERS and some
1617 LABELS. Also note whether the asm-statement should be
1618 considered volatile, and whether it is asm inline. */
1619
1620tree
1621finish_asm_stmt (location_t loc, int volatile_p, tree string,
1622 tree output_operands, tree input_operands, tree clobbers,
1623 tree labels, bool inline_p)
1624{
1625 tree r;
1626 tree t;
1627 int ninputs = list_length (input_operands);
1628 int noutputs = list_length (output_operands);
1629
1630 if (!processing_template_declscope_chain->x_processing_template_decl)
1631 {
1632 const char *constraint;
1633 const char **oconstraints;
1634 bool allows_mem, allows_reg, is_inout;
1635 tree operand;
1636 int i;
1637
1638 oconstraints = XALLOCAVEC (const char *, noutputs)((const char * *) __builtin_alloca(sizeof (const char *) * (noutputs
)))
;
1639
1640 string = resolve_asm_operand_names (string, output_operands,
1641 input_operands, labels);
1642
1643 for (i = 0, t = output_operands; t; t = TREE_CHAIN (t)((contains_struct_check ((t), (TS_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1643, __FUNCTION__))->common.chain)
, ++i)
1644 {
1645 operand = TREE_VALUE (t)((tree_check ((t), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1645, __FUNCTION__, (TREE_LIST)))->list.value)
;
1646
1647 /* ??? Really, this should not be here. Users should be using a
1648 proper lvalue, dammit. But there's a long history of using
1649 casts in the output operands. In cases like longlong.h, this
1650 becomes a primitive form of typechecking -- if the cast can be
1651 removed, then the output operand had a type of the proper width;
1652 otherwise we'll get an error. Gross, but ... */
1653 STRIP_NOPS (operand)(operand) = tree_strip_nop_conversions ((const_cast<union tree_node
*> (((operand)))))
;
1654
1655 operand = mark_lvalue_use (operand);
1656
1657 if (!lvalue_or_else (operand, lv_asm, tf_warning_or_error))
1658 operand = error_mark_nodeglobal_trees[TI_ERROR_MARK];
1659
1660 if (operand != error_mark_nodeglobal_trees[TI_ERROR_MARK]
1661 && (TREE_READONLY (operand)((non_type_check ((operand), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1661, __FUNCTION__))->base.readonly_flag)
1662 || CP_TYPE_CONST_P (TREE_TYPE (operand))((cp_type_quals (((contains_struct_check ((operand), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1662, __FUNCTION__))->typed.type)) & TYPE_QUAL_CONST
) != 0)
1663 /* Functions are not modifiable, even though they are
1664 lvalues. */
1665 || FUNC_OR_METHOD_TYPE_P (TREE_TYPE (operand))(((enum tree_code) (((contains_struct_check ((operand), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1665, __FUNCTION__))->typed.type))->base.code) == FUNCTION_TYPE
|| ((enum tree_code) (((contains_struct_check ((operand), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1665, __FUNCTION__))->typed.type))->base.code) == METHOD_TYPE
)
1666 /* If it's an aggregate and any field is const, then it is
1667 effectively const. */
1668 || (CLASS_TYPE_P (TREE_TYPE (operand))(((((enum tree_code) (((contains_struct_check ((operand), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1668, __FUNCTION__))->typed.type))->base.code)) == RECORD_TYPE
|| (((enum tree_code) (((contains_struct_check ((operand), (
TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1668, __FUNCTION__))->typed.type))->base.code)) == UNION_TYPE
) && ((tree_class_check ((((contains_struct_check ((operand
), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1668, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1668, __FUNCTION__))->type_common.lang_flag_5))
1669 && C_TYPE_FIELDS_READONLY (TREE_TYPE (operand))((((tree_class_check ((((contains_struct_check ((operand), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1669, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1669, __FUNCTION__))->type_with_lang_specific.lang_specific
))->fields_readonly)
)))
1670 cxx_readonly_error (loc, operand, lv_asm);
1671
1672 tree *op = &operand;
1673 while (TREE_CODE (*op)((enum tree_code) (*op)->base.code) == COMPOUND_EXPR)
1674 op = &TREE_OPERAND (*op, 1)(*((const_cast<tree*> (tree_operand_check ((*op), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1674, __FUNCTION__)))))
;
1675 switch (TREE_CODE (*op)((enum tree_code) (*op)->base.code))
1676 {
1677 case PREINCREMENT_EXPR:
1678 case PREDECREMENT_EXPR:
1679 case MODIFY_EXPR:
1680 *op = genericize_compound_lvalue (*op);
1681 op = &TREE_OPERAND (*op, 1)(*((const_cast<tree*> (tree_operand_check ((*op), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1681, __FUNCTION__)))))
;
1682 break;
1683 default:
1684 break;
1685 }
1686
1687 constraint = TREE_STRING_POINTER (TREE_VALUE (TREE_PURPOSE (t)))((const char *)((tree_check ((((tree_check ((((tree_check ((t
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1687, __FUNCTION__, (TREE_LIST)))->list.purpose)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1687, __FUNCTION__, (TREE_LIST)))->list.value)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1687, __FUNCTION__, (STRING_CST)))->string.str))
;
1688 oconstraints[i] = constraint;
1689
1690 if (parse_output_constraint (&constraint, i, ninputs, noutputs,
1691 &allows_mem, &allows_reg, &is_inout))
1692 {
1693 /* If the operand is going to end up in memory,
1694 mark it addressable. */
1695 if (!allows_reg && !cxx_mark_addressable (*op))
1696 operand = error_mark_nodeglobal_trees[TI_ERROR_MARK];
1697 }
1698 else
1699 operand = error_mark_nodeglobal_trees[TI_ERROR_MARK];
1700
1701 TREE_VALUE (t)((tree_check ((t), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1701, __FUNCTION__, (TREE_LIST)))->list.value)
= operand;
1702 }
1703
1704 for (i = 0, t = input_operands; t; ++i, t = TREE_CHAIN (t)((contains_struct_check ((t), (TS_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1704, __FUNCTION__))->common.chain)
)
1705 {
1706 constraint = TREE_STRING_POINTER (TREE_VALUE (TREE_PURPOSE (t)))((const char *)((tree_check ((((tree_check ((((tree_check ((t
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1706, __FUNCTION__, (TREE_LIST)))->list.purpose)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1706, __FUNCTION__, (TREE_LIST)))->list.value)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1706, __FUNCTION__, (STRING_CST)))->string.str))
;
1707 bool constraint_parsed
1708 = parse_input_constraint (&constraint, i, ninputs, noutputs, 0,
1709 oconstraints, &allows_mem, &allows_reg);
1710 /* If the operand is going to end up in memory, don't call
1711 decay_conversion. */
1712 if (constraint_parsed && !allows_reg && allows_mem)
1713 operand = mark_lvalue_use (TREE_VALUE (t)((tree_check ((t), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1713, __FUNCTION__, (TREE_LIST)))->list.value)
);
1714 else
1715 operand = decay_conversion (TREE_VALUE (t)((tree_check ((t), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1715, __FUNCTION__, (TREE_LIST)))->list.value)
, tf_warning_or_error);
1716
1717 /* If the type of the operand hasn't been determined (e.g.,
1718 because it involves an overloaded function), then issue
1719 an error message. There's no context available to
1720 resolve the overloading. */
1721 if (TREE_TYPE (operand)((contains_struct_check ((operand), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1721, __FUNCTION__))->typed.type)
== unknown_type_nodecp_global_trees[CPTI_UNKNOWN_TYPE])
1722 {
1723 error_at (loc,
1724 "type of %<asm%> operand %qE could not be determined",
1725 TREE_VALUE (t)((tree_check ((t), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1725, __FUNCTION__, (TREE_LIST)))->list.value)
);
1726 operand = error_mark_nodeglobal_trees[TI_ERROR_MARK];
1727 }
1728
1729 if (constraint_parsed)
1730 {
1731 /* If the operand is going to end up in memory,
1732 mark it addressable. */
1733 if (!allows_reg && allows_mem)
1734 {
1735 /* Strip the nops as we allow this case. FIXME, this really
1736 should be rejected or made deprecated. */
1737 STRIP_NOPS (operand)(operand) = tree_strip_nop_conversions ((const_cast<union tree_node
*> (((operand)))))
;
1738
1739 tree *op = &operand;
1740 while (TREE_CODE (*op)((enum tree_code) (*op)->base.code) == COMPOUND_EXPR)
1741 op = &TREE_OPERAND (*op, 1)(*((const_cast<tree*> (tree_operand_check ((*op), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1741, __FUNCTION__)))))
;
1742 switch (TREE_CODE (*op)((enum tree_code) (*op)->base.code))
1743 {
1744 case PREINCREMENT_EXPR:
1745 case PREDECREMENT_EXPR:
1746 case MODIFY_EXPR:
1747 *op = genericize_compound_lvalue (*op);
1748 op = &TREE_OPERAND (*op, 1)(*((const_cast<tree*> (tree_operand_check ((*op), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1748, __FUNCTION__)))))
;
1749 break;
1750 default:
1751 break;
1752 }
1753
1754 if (!cxx_mark_addressable (*op))
1755 operand = error_mark_nodeglobal_trees[TI_ERROR_MARK];
1756 }
1757 else if (!allows_reg && !allows_mem)
1758 {
1759 /* If constraint allows neither register nor memory,
1760 try harder to get a constant. */
1761 tree constop = maybe_constant_value (operand);
1762 if (TREE_CONSTANT (constop)((non_type_check ((constop), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1762, __FUNCTION__))->base.constant_flag)
)
1763 operand = constop;
1764 }
1765 }
1766 else
1767 operand = error_mark_nodeglobal_trees[TI_ERROR_MARK];
1768
1769 TREE_VALUE (t)((tree_check ((t), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1769, __FUNCTION__, (TREE_LIST)))->list.value)
= operand;
1770 }
1771 }
1772
1773 r = build_stmt (loc, ASM_EXPR, string,
1774 output_operands, input_operands,
1775 clobbers, labels);
1776 ASM_VOLATILE_P (r)((tree_check ((r), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1776, __FUNCTION__, (ASM_EXPR)))->base.public_flag)
= volatile_p || noutputs == 0;
1777 ASM_INLINE_P (r)((tree_check ((r), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1777, __FUNCTION__, (ASM_EXPR)))->base.protected_flag)
= inline_p;
1778 r = maybe_cleanup_point_expr_void (r);
1779 return add_stmt (r);
1780}
1781
1782/* Finish a label with the indicated NAME. Returns the new label. */
1783
1784tree
1785finish_label_stmt (tree name)
1786{
1787 tree decl = define_label (input_location, name);
1788
1789 if (decl == error_mark_nodeglobal_trees[TI_ERROR_MARK])
1790 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
1791
1792 add_stmt (build_stmt (input_location, LABEL_EXPR, decl));
1793
1794 return decl;
1795}
1796
1797/* Finish a series of declarations for local labels. G++ allows users
1798 to declare "local" labels, i.e., labels with scope. This extension
1799 is useful when writing code involving statement-expressions. */
1800
1801void
1802finish_label_decl (tree name)
1803{
1804 if (!at_function_scope_p ())
1805 {
1806 error ("%<__label__%> declarations are only allowed in function scopes");
1807 return;
1808 }
1809
1810 add_decl_expr (declare_local_label (name));
1811}
1812
1813/* When DECL goes out of scope, make sure that CLEANUP is executed. */
1814
1815void
1816finish_decl_cleanup (tree decl, tree cleanup)
1817{
1818 push_cleanup (decl, cleanup, false);
1819}
1820
1821/* If the current scope exits with an exception, run CLEANUP. */
1822
1823void
1824finish_eh_cleanup (tree cleanup)
1825{
1826 push_cleanup (NULL__null, cleanup, true);
1827}
1828
1829/* The MEM_INITS is a list of mem-initializers, in reverse of the
1830 order they were written by the user. Each node is as for
1831 emit_mem_initializers. */
1832
1833void
1834finish_mem_initializers (tree mem_inits)
1835{
1836 /* Reorder the MEM_INITS so that they are in the order they appeared
1837 in the source program. */
1838 mem_inits = nreverse (mem_inits);
1839
1840 if (processing_template_declscope_chain->x_processing_template_decl)
1841 {
1842 tree mem;
1843
1844 for (mem = mem_inits; mem; mem = TREE_CHAIN (mem)((contains_struct_check ((mem), (TS_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1844, __FUNCTION__))->common.chain)
)
1845 {
1846 /* If the TREE_PURPOSE is a TYPE_PACK_EXPANSION, skip the
1847 check for bare parameter packs in the TREE_VALUE, because
1848 any parameter packs in the TREE_VALUE have already been
1849 bound as part of the TREE_PURPOSE. See
1850 make_pack_expansion for more information. */
1851 if (TREE_CODE (TREE_PURPOSE (mem))((enum tree_code) (((tree_check ((mem), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1851, __FUNCTION__, (TREE_LIST)))->list.purpose))->base
.code)
!= TYPE_PACK_EXPANSION
1852 && check_for_bare_parameter_packs (TREE_VALUE (mem)((tree_check ((mem), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1852, __FUNCTION__, (TREE_LIST)))->list.value)
))
1853 TREE_VALUE (mem)((tree_check ((mem), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1853, __FUNCTION__, (TREE_LIST)))->list.value)
= error_mark_nodeglobal_trees[TI_ERROR_MARK];
1854 }
1855
1856 add_stmt (build_min_nt_loc (UNKNOWN_LOCATION((location_t) 0),
1857 CTOR_INITIALIZER, mem_inits));
1858 }
1859 else
1860 emit_mem_initializers (mem_inits);
1861}
1862
1863/* Obfuscate EXPR if it looks like an id-expression or member access so
1864 that the call to finish_decltype in do_auto_deduction will give the
1865 right result. If EVEN_UNEVAL, do this even in unevaluated context. */
1866
1867tree
1868force_paren_expr (tree expr, bool even_uneval)
1869{
1870 /* This is only needed for decltype(auto) in C++14. */
1871 if (cxx_dialect < cxx14)
1872 return expr;
1873
1874 /* If we're in unevaluated context, we can't be deducing a
1875 return/initializer type, so we don't need to mess with this. */
1876 if (cp_unevaluated_operand && !even_uneval)
1877 return expr;
1878
1879 if (!DECL_P (tree_strip_any_location_wrapper (expr))(tree_code_type[(int) (((enum tree_code) (tree_strip_any_location_wrapper
(expr))->base.code))] == tcc_declaration)
1880 && TREE_CODE (expr)((enum tree_code) (expr)->base.code) != COMPONENT_REF
1881 && TREE_CODE (expr)((enum tree_code) (expr)->base.code) != SCOPE_REF)
1882 return expr;
1883
1884 location_t loc = cp_expr_location (expr);
1885
1886 if (TREE_CODE (expr)((enum tree_code) (expr)->base.code) == COMPONENT_REF
1887 || TREE_CODE (expr)((enum tree_code) (expr)->base.code) == SCOPE_REF)
1888 REF_PARENTHESIZED_P (expr)((tree_not_check2 (((tree_check4 (((expr)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1888, __FUNCTION__, (COMPONENT_REF), (INDIRECT_REF), (SCOPE_REF
), (VIEW_CONVERT_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1888, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_2)
= true;
1889 else if (processing_template_declscope_chain->x_processing_template_decl)
1890 expr = build1_loc (loc, PAREN_EXPR, TREE_TYPE (expr)((contains_struct_check ((expr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1890, __FUNCTION__))->typed.type)
, expr);
1891 else
1892 {
1893 expr = build1_loc (loc, VIEW_CONVERT_EXPR, TREE_TYPE (expr)((contains_struct_check ((expr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1893, __FUNCTION__))->typed.type)
, expr);
1894 REF_PARENTHESIZED_P (expr)((tree_not_check2 (((tree_check4 (((expr)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1894, __FUNCTION__, (COMPONENT_REF), (INDIRECT_REF), (SCOPE_REF
), (VIEW_CONVERT_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1894, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_2)
= true;
1895 }
1896
1897 return expr;
1898}
1899
1900/* If T is an id-expression obfuscated by force_paren_expr, undo the
1901 obfuscation and return the underlying id-expression. Otherwise
1902 return T. */
1903
1904tree
1905maybe_undo_parenthesized_ref (tree t)
1906{
1907 if (cxx_dialect < cxx14)
1908 return t;
1909
1910 if (INDIRECT_REF_P (t)(((enum tree_code) (t)->base.code) == INDIRECT_REF) && REF_PARENTHESIZED_P (t)((tree_not_check2 (((tree_check4 (((t)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1910, __FUNCTION__, (COMPONENT_REF), (INDIRECT_REF), (SCOPE_REF
), (VIEW_CONVERT_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1910, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_2)
)
1911 {
1912 t = TREE_OPERAND (t, 0)(*((const_cast<tree*> (tree_operand_check ((t), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1912, __FUNCTION__)))))
;
1913 while (TREE_CODE (t)((enum tree_code) (t)->base.code) == NON_LVALUE_EXPR
1914 || TREE_CODE (t)((enum tree_code) (t)->base.code) == NOP_EXPR)
1915 t = TREE_OPERAND (t, 0)(*((const_cast<tree*> (tree_operand_check ((t), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1915, __FUNCTION__)))))
;
1916
1917 gcc_assert (TREE_CODE (t) == ADDR_EXPR((void)(!(((enum tree_code) (t)->base.code) == ADDR_EXPR ||
((enum tree_code) (t)->base.code) == STATIC_CAST_EXPR) ? fancy_abort
("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1918, __FUNCTION__), 0 : 0))
1918 || TREE_CODE (t) == STATIC_CAST_EXPR)((void)(!(((enum tree_code) (t)->base.code) == ADDR_EXPR ||
((enum tree_code) (t)->base.code) == STATIC_CAST_EXPR) ? fancy_abort
("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1918, __FUNCTION__), 0 : 0))
;
1919 t = TREE_OPERAND (t, 0)(*((const_cast<tree*> (tree_operand_check ((t), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1919, __FUNCTION__)))))
;
1920 }
1921 else if (TREE_CODE (t)((enum tree_code) (t)->base.code) == PAREN_EXPR)
1922 t = TREE_OPERAND (t, 0)(*((const_cast<tree*> (tree_operand_check ((t), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1922, __FUNCTION__)))))
;
1923 else if (TREE_CODE (t)((enum tree_code) (t)->base.code) == VIEW_CONVERT_EXPR
1924 && REF_PARENTHESIZED_P (t)((tree_not_check2 (((tree_check4 (((t)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1924, __FUNCTION__, (COMPONENT_REF), (INDIRECT_REF), (SCOPE_REF
), (VIEW_CONVERT_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1924, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_2)
)
1925 t = TREE_OPERAND (t, 0)(*((const_cast<tree*> (tree_operand_check ((t), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1925, __FUNCTION__)))))
;
1926
1927 return t;
1928}
1929
1930/* Finish a parenthesized expression EXPR. */
1931
1932cp_expr
1933finish_parenthesized_expr (cp_expr expr)
1934{
1935 if (EXPR_P (expr)((tree_code_type[(int) (((enum tree_code) (expr)->base.code
))]) >= tcc_reference && (tree_code_type[(int) (((
enum tree_code) (expr)->base.code))]) <= tcc_expression
)
)
1936 /* This inhibits warnings in c_common_truthvalue_conversion. */
1937 TREE_NO_WARNING (expr)((expr)->base.nowarning_flag) = 1;
1938
1939 if (TREE_CODE (expr)((enum tree_code) (expr)->base.code) == OFFSET_REF
1940 || TREE_CODE (expr)((enum tree_code) (expr)->base.code) == SCOPE_REF)
1941 /* [expr.unary.op]/3 The qualified id of a pointer-to-member must not be
1942 enclosed in parentheses. */
1943 PTRMEM_OK_P (expr)((tree_not_check2 (((tree_check3 (((expr)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1943, __FUNCTION__, (ADDR_EXPR), (OFFSET_REF), (SCOPE_REF))
)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1943, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_0)
= 0;
1944
1945 tree stripped_expr = tree_strip_any_location_wrapper (expr);
1946 if (TREE_CODE (stripped_expr)((enum tree_code) (stripped_expr)->base.code) == STRING_CST)
1947 PAREN_STRING_LITERAL_P (stripped_expr)((tree_not_check2 (((tree_check ((stripped_expr), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1947, __FUNCTION__, (STRING_CST)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1947, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_0)
= 1;
1948
1949 expr = cp_expr (force_paren_expr (expr), expr.get_location ());
1950
1951 return expr;
1952}
1953
1954/* Finish a reference to a non-static data member (DECL) that is not
1955 preceded by `.' or `->'. */
1956
1957tree
1958finish_non_static_data_member (tree decl, tree object, tree qualifying_scope)
1959{
1960 gcc_assert (TREE_CODE (decl) == FIELD_DECL)((void)(!(((enum tree_code) (decl)->base.code) == FIELD_DECL
) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1960, __FUNCTION__), 0 : 0))
;
1961 bool try_omp_private = !object && omp_private_member_map;
1962 tree ret;
1963
1964 if (!object)
1965 {
1966 tree scope = qualifying_scope;
1967 if (scope == NULL_TREE(tree) __null)
1968 {
1969 scope = context_for_name_lookup (decl);
1970 if (!TYPE_P (scope)(tree_code_type[(int) (((enum tree_code) (scope)->base.code
))] == tcc_type)
)
1971 {
1972 /* Can happen during error recovery (c++/85014). */
1973 gcc_assert (seen_error ())((void)(!(seen_error ()) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1973, __FUNCTION__), 0 : 0))
;
1974 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
1975 }
1976 }
1977 object = maybe_dummy_object (scope, NULL__null);
1978 }
1979
1980 object = maybe_resolve_dummy (object, true);
1981 if (object == error_mark_nodeglobal_trees[TI_ERROR_MARK])
1982 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
1983
1984 /* DR 613/850: Can use non-static data members without an associated
1985 object in sizeof/decltype/alignof. */
1986 if (is_dummy_object (object) && cp_unevaluated_operand == 0
1987 && (!processing_template_declscope_chain->x_processing_template_decl || !current_class_ref(*((cfun + 0) && ((cfun + 0)->language) ? &((cfun
+ 0)->language)->x_current_class_ref : &scope_chain
->x_current_class_ref))
))
1988 {
1989 if (current_function_decl
1990 && DECL_STATIC_FUNCTION_P (current_function_decl)(__extension__ ({ struct lang_decl *lt = ((contains_struct_check
(((((enum tree_code) (current_function_decl)->base.code) ==
TEMPLATE_DECL ? ((struct tree_template_decl *)(const_cast<
union tree_node *> ((((tree_check ((current_function_decl)
, "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1990, __FUNCTION__, (TEMPLATE_DECL))))))))->result : current_function_decl
)), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1990, __FUNCTION__))->decl_common.lang_specific); if (!(
((enum tree_code) (current_function_decl)->base.code) == FUNCTION_DECL
|| (((enum tree_code) (current_function_decl)->base.code)
== TEMPLATE_DECL && ((struct tree_template_decl *)(const_cast
<union tree_node *> ((((tree_check ((current_function_decl
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1990, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((current_function_decl
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1990, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)) || lt->u.base.selector != lds_fn
) lang_check_failed ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1990, __FUNCTION__); &lt->u.fn; })->static_function
)
)
1991 error ("invalid use of member %qD in static member function", decl);
1992 else
1993 error ("invalid use of non-static data member %qD", decl);
1994 inform (DECL_SOURCE_LOCATION (decl)((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 1994, __FUNCTION__))->decl_minimal.locus)
, "declared here");
1995
1996 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
1997 }
1998
1999 if (current_class_ptr(*((cfun + 0) && ((cfun + 0)->language) ? &((cfun
+ 0)->language)->x_current_class_ptr : &scope_chain
->x_current_class_ptr))
)
2000 TREE_USED (current_class_ptr)(((*((cfun + 0) && ((cfun + 0)->language) ? &(
(cfun + 0)->language)->x_current_class_ptr : &scope_chain
->x_current_class_ptr)))->base.used_flag)
= 1;
2001 if (processing_template_declscope_chain->x_processing_template_decl)
2002 {
2003 tree type = TREE_TYPE (decl)((contains_struct_check ((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2003, __FUNCTION__))->typed.type)
;
2004
2005 if (TYPE_REF_P (type)(((enum tree_code) (type)->base.code) == REFERENCE_TYPE))
2006 /* Quals on the object don't matter. */;
2007 else if (PACK_EXPANSION_P (type)(((enum tree_code) (type)->base.code) == TYPE_PACK_EXPANSION
|| ((enum tree_code) (type)->base.code) == EXPR_PACK_EXPANSION
)
)
2008 /* Don't bother trying to represent this. */
2009 type = NULL_TREE(tree) __null;
2010 else
2011 {
2012 /* Set the cv qualifiers. */
2013 int quals = cp_type_quals (TREE_TYPE (object)((contains_struct_check ((object), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2013, __FUNCTION__))->typed.type)
);
2014
2015 if (DECL_MUTABLE_P (decl)(((contains_struct_check (((tree_check ((decl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2015, __FUNCTION__, (FIELD_DECL)))), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2015, __FUNCTION__))->decl_common.lang_flag_0))
)
2016 quals &= ~TYPE_QUAL_CONST;
2017
2018 quals |= cp_type_quals (TREE_TYPE (decl)((contains_struct_check ((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2018, __FUNCTION__))->typed.type)
);
2019 type = cp_build_qualified_type (type, quals)cp_build_qualified_type_real ((type), (quals), tf_warning_or_error
)
;
2020 }
2021
2022 if (qualifying_scope)
2023 /* Wrap this in a SCOPE_REF for now. */
2024 ret = build_qualified_name (type, qualifying_scope, decl,
2025 /*template_p=*/false);
2026 else
2027 ret = (convert_from_reference
2028 (build_min (COMPONENT_REF, type, object, decl, NULL_TREE(tree) __null)));
2029 }
2030 /* If PROCESSING_TEMPLATE_DECL is nonzero here, then
2031 QUALIFYING_SCOPE is also non-null. */
2032 else
2033 {
2034 tree access_type = TREE_TYPE (object)((contains_struct_check ((object), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2034, __FUNCTION__))->typed.type)
;
2035
2036 perform_or_defer_access_check (TYPE_BINFO (access_type)((tree_check3 ((access_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2036, __FUNCTION__, (RECORD_TYPE), (UNION_TYPE), (QUAL_UNION_TYPE
)))->type_non_common.maxval)
, decl,
2037 decl, tf_warning_or_error);
2038
2039 /* If the data member was named `C::M', convert `*this' to `C'
2040 first. */
2041 if (qualifying_scope)
2042 {
2043 tree binfo = NULL_TREE(tree) __null;
2044 object = build_scoped_ref (object, qualifying_scope,
2045 &binfo);
2046 }
2047
2048 ret = build_class_member_access_expr (object, decl,
2049 /*access_path=*/NULL_TREE(tree) __null,
2050 /*preserve_reference=*/false,
2051 tf_warning_or_error);
2052 }
2053 if (try_omp_private)
2054 {
2055 tree *v = omp_private_member_map->get (decl);
2056 if (v)
2057 ret = convert_from_reference (*v);
2058 }
2059 return ret;
2060}
2061
2062/* DECL was the declaration to which a qualified-id resolved. Issue
2063 an error message if it is not accessible. If OBJECT_TYPE is
2064 non-NULL, we have just seen `x->' or `x.' and OBJECT_TYPE is the
2065 type of `*x', or `x', respectively. If the DECL was named as
2066 `A::B' then NESTED_NAME_SPECIFIER is `A'. Return value is like
2067 perform_access_checks above. */
2068
2069bool
2070check_accessibility_of_qualified_id (tree decl,
2071 tree object_type,
2072 tree nested_name_specifier,
2073 tsubst_flags_t complain)
2074{
2075 /* If we're not checking, return immediately. */
2076 if (deferred_access_no_check)
2077 return true;
2078
2079 /* Determine the SCOPE of DECL. */
2080 tree scope = context_for_name_lookup (decl);
2081 /* If the SCOPE is not a type, then DECL is not a member. */
2082 if (!TYPE_P (scope)(tree_code_type[(int) (((enum tree_code) (scope)->base.code
))] == tcc_type)
2083 /* If SCOPE is dependent then we can't perform this access check now,
2084 and since we'll perform this access check again after substitution
2085 there's no need to explicitly defer it. */
2086 || dependent_type_p (scope))
2087 return true;
2088
2089 tree qualifying_type = NULL_TREE(tree) __null;
2090 /* Compute the scope through which DECL is being accessed. */
2091 if (object_type
2092 /* OBJECT_TYPE might not be a class type; consider:
2093
2094 class A { typedef int I; };
2095 I *p;
2096 p->A::I::~I();
2097
2098 In this case, we will have "A::I" as the DECL, but "I" as the
2099 OBJECT_TYPE. */
2100 && CLASS_TYPE_P (object_type)(((((enum tree_code) (object_type)->base.code)) == RECORD_TYPE
|| (((enum tree_code) (object_type)->base.code)) == UNION_TYPE
) && ((tree_class_check ((object_type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2100, __FUNCTION__))->type_common.lang_flag_5))
2101 && DERIVED_FROM_P (scope, object_type)(lookup_base ((object_type), (scope), ba_any, __null, tf_none
) != (tree) __null)
)
2102 /* If we are processing a `->' or `.' expression, use the type of the
2103 left-hand side. */
2104 qualifying_type = object_type;
2105 else if (nested_name_specifier)
2106 {
2107 /* If the reference is to a non-static member of the
2108 current class, treat it as if it were referenced through
2109 `this'. */
2110 if (DECL_NONSTATIC_MEMBER_P (decl)((((enum tree_code) (((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2110, __FUNCTION__))->typed.type))->base.code) == METHOD_TYPE
) || ((enum tree_code) (decl)->base.code) == FIELD_DECL)
2111 && current_class_ptr(*((cfun + 0) && ((cfun + 0)->language) ? &((cfun
+ 0)->language)->x_current_class_ptr : &scope_chain
->x_current_class_ptr))
)
2112 if (tree current = current_nonlambda_class_type ())
2113 {
2114 if (dependent_type_p (current))
2115 /* In general we can't know whether this access goes through
2116 `this' until instantiation time. Punt now, or else we might
2117 create a deferred access check that's not relative to `this'
2118 when it ought to be. We'll check this access again after
2119 substitution, e.g. from tsubst_qualified_id. */
2120 return true;
2121
2122 if (DERIVED_FROM_P (scope, current)(lookup_base ((current), (scope), ba_any, __null, tf_none) !=
(tree) __null)
)
2123 qualifying_type = current;
2124 }
2125 /* Otherwise, use the type indicated by the
2126 nested-name-specifier. */
2127 if (!qualifying_type)
2128 qualifying_type = nested_name_specifier;
2129 }
2130 else
2131 /* Otherwise, the name must be from the current class or one of
2132 its bases. */
2133 qualifying_type = currently_open_derived_class (scope);
2134
2135 if (qualifying_type
2136 /* It is possible for qualifying type to be a TEMPLATE_TYPE_PARM
2137 or similar in a default argument value. */
2138 && CLASS_TYPE_P (qualifying_type)(((((enum tree_code) (qualifying_type)->base.code)) == RECORD_TYPE
|| (((enum tree_code) (qualifying_type)->base.code)) == UNION_TYPE
) && ((tree_class_check ((qualifying_type), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2138, __FUNCTION__))->type_common.lang_flag_5))
)
2139 return perform_or_defer_access_check (TYPE_BINFO (qualifying_type)((tree_check3 ((qualifying_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2139, __FUNCTION__, (RECORD_TYPE), (UNION_TYPE), (QUAL_UNION_TYPE
)))->type_non_common.maxval)
, decl,
2140 decl, complain);
2141
2142 return true;
2143}
2144
2145/* EXPR is the result of a qualified-id. The QUALIFYING_CLASS was the
2146 class named to the left of the "::" operator. DONE is true if this
2147 expression is a complete postfix-expression; it is false if this
2148 expression is followed by '->', '[', '(', etc. ADDRESS_P is true
2149 iff this expression is the operand of '&'. TEMPLATE_P is true iff
2150 the qualified-id was of the form "A::template B". TEMPLATE_ARG_P
2151 is true iff this qualified name appears as a template argument. */
2152
2153tree
2154finish_qualified_id_expr (tree qualifying_class,
2155 tree expr,
2156 bool done,
2157 bool address_p,
2158 bool template_p,
2159 bool template_arg_p,
2160 tsubst_flags_t complain)
2161{
2162 gcc_assert (TYPE_P (qualifying_class))((void)(!((tree_code_type[(int) (((enum tree_code) (qualifying_class
)->base.code))] == tcc_type)) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2162, __FUNCTION__), 0 : 0))
;
2163
2164 if (error_operand_p (expr)((expr) == global_trees[TI_ERROR_MARK] || ((expr) && (
(contains_struct_check (((expr)), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2164, __FUNCTION__))->typed.type) == global_trees[TI_ERROR_MARK
]))
)
2165 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
2166
2167 if ((DECL_P (expr)(tree_code_type[(int) (((enum tree_code) (expr)->base.code
))] == tcc_declaration)
|| BASELINK_P (expr)(((enum tree_code) (expr)->base.code) == BASELINK))
2168 && !mark_used (expr, complain))
2169 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
2170
2171 if (template_p)
2172 {
2173 if (TREE_CODE (expr)((enum tree_code) (expr)->base.code) == UNBOUND_CLASS_TEMPLATE)
2174 {
2175 /* cp_parser_lookup_name thought we were looking for a type,
2176 but we're actually looking for a declaration. */
2177 qualifying_class = TYPE_CONTEXT (expr)((tree_class_check ((expr), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2177, __FUNCTION__))->type_common.context)
;
2178 expr = TYPE_IDENTIFIER (expr)(((tree_class_check ((expr), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2178, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((expr), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2178, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((expr), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2178, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2178, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((expr), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2178, __FUNCTION__))->type_common.name))
;
2179 }
2180 else
2181 check_template_keyword (expr);
2182 }
2183
2184 /* If EXPR occurs as the operand of '&', use special handling that
2185 permits a pointer-to-member. */
2186 if (address_p && done)
2187 {
2188 if (TREE_CODE (expr)((enum tree_code) (expr)->base.code) == SCOPE_REF)
2189 expr = TREE_OPERAND (expr, 1)(*((const_cast<tree*> (tree_operand_check ((expr), (1),
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2189, __FUNCTION__)))))
;
2190 expr = build_offset_ref (qualifying_class, expr,
2191 /*address_p=*/true, complain);
2192 return expr;
2193 }
2194
2195 /* No need to check access within an enum. */
2196 if (TREE_CODE (qualifying_class)((enum tree_code) (qualifying_class)->base.code) == ENUMERAL_TYPE
2197 && TREE_CODE (expr)((enum tree_code) (expr)->base.code) != IDENTIFIER_NODE)
2198 return expr;
2199
2200 /* Within the scope of a class, turn references to non-static
2201 members into expression of the form "this->...". */
2202 if (template_arg_p)
2203 /* But, within a template argument, we do not want make the
2204 transformation, as there is no "this" pointer. */
2205 ;
2206 else if (TREE_CODE (expr)((enum tree_code) (expr)->base.code) == FIELD_DECL)
2207 {
2208 push_deferring_access_checks (dk_no_check);
2209 expr = finish_non_static_data_member (expr, NULL_TREE(tree) __null,
2210 qualifying_class);
2211 pop_deferring_access_checks ();
2212 }
2213 else if (BASELINK_P (expr)(((enum tree_code) (expr)->base.code) == BASELINK))
2214 {
2215 /* See if any of the functions are non-static members. */
2216 /* If so, the expression may be relative to 'this'. */
2217 if ((type_dependent_expression_p (expr)
2218 || !shared_member_p (expr))
2219 && current_class_ptr(*((cfun + 0) && ((cfun + 0)->language) ? &((cfun
+ 0)->language)->x_current_class_ptr : &scope_chain
->x_current_class_ptr))
2220 && DERIVED_FROM_P (qualifying_class,(lookup_base ((current_nonlambda_class_type ()), (qualifying_class
), ba_any, __null, tf_none) != (tree) __null)
2221 current_nonlambda_class_type ())(lookup_base ((current_nonlambda_class_type ()), (qualifying_class
), ba_any, __null, tf_none) != (tree) __null)
)
2222 expr = (build_class_member_access_expr
2223 (maybe_dummy_object (qualifying_class, NULL__null),
2224 expr,
2225 BASELINK_ACCESS_BINFO (expr)(((struct tree_baselink*) (tree_check ((expr), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2225, __FUNCTION__, (BASELINK))))->access_binfo)
,
2226 /*preserve_reference=*/false,
2227 complain));
2228 else if (done)
2229 /* The expression is a qualified name whose address is not
2230 being taken. */
2231 expr = build_offset_ref (qualifying_class, expr, /*address_p=*/false,
2232 complain);
2233 }
2234 else if (!template_p
2235 && TREE_CODE (expr)((enum tree_code) (expr)->base.code) == TEMPLATE_DECL
2236 && !DECL_FUNCTION_TEMPLATE_P (expr)(((enum tree_code) (expr)->base.code) == TEMPLATE_DECL &&
((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((expr), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2236, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((expr
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2236, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)
)
2237 {
2238 if (complain & tf_error)
2239 error ("%qE missing template arguments", expr);
2240 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
2241 }
2242 else
2243 {
2244 /* In a template, return a SCOPE_REF for most qualified-ids
2245 so that we can check access at instantiation time. But if
2246 we're looking at a member of the current instantiation, we
2247 know we have access and building up the SCOPE_REF confuses
2248 non-type template argument handling. */
2249 if (processing_template_declscope_chain->x_processing_template_decl
2250 && (!currently_open_class (qualifying_class)
2251 || TREE_CODE (expr)((enum tree_code) (expr)->base.code) == IDENTIFIER_NODE
2252 || TREE_CODE (expr)((enum tree_code) (expr)->base.code) == TEMPLATE_ID_EXPR
2253 || TREE_CODE (expr)((enum tree_code) (expr)->base.code) == BIT_NOT_EXPR))
2254 expr = build_qualified_name (TREE_TYPE (expr)((contains_struct_check ((expr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2254, __FUNCTION__))->typed.type)
,
2255 qualifying_class, expr,
2256 template_p);
2257 else if (tree wrap = maybe_get_tls_wrapper_call (expr))
2258 expr = wrap;
2259
2260 expr = convert_from_reference (expr);
2261 }
2262
2263 return expr;
2264}
2265
2266/* Begin a statement-expression. The value returned must be passed to
2267 finish_stmt_expr. */
2268
2269tree
2270begin_stmt_expr (void)
2271{
2272 return push_stmt_list ();
2273}
2274
2275/* Process the final expression of a statement expression. EXPR can be
2276 NULL, if the final expression is empty. Return a STATEMENT_LIST
2277 containing all the statements in the statement-expression, or
2278 ERROR_MARK_NODE if there was an error. */
2279
2280tree
2281finish_stmt_expr_expr (tree expr, tree stmt_expr)
2282{
2283 if (error_operand_p (expr)((expr) == global_trees[TI_ERROR_MARK] || ((expr) && (
(contains_struct_check (((expr)), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2283, __FUNCTION__))->typed.type) == global_trees[TI_ERROR_MARK
]))
)
2284 {
2285 /* The type of the statement-expression is the type of the last
2286 expression. */
2287 TREE_TYPE (stmt_expr)((contains_struct_check ((stmt_expr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2287, __FUNCTION__))->typed.type)
= error_mark_nodeglobal_trees[TI_ERROR_MARK];
2288 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
2289 }
2290
2291 /* If the last statement does not have "void" type, then the value
2292 of the last statement is the value of the entire expression. */
2293 if (expr)
2294 {
2295 tree type = TREE_TYPE (expr)((contains_struct_check ((expr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2295, __FUNCTION__))->typed.type)
;
2296
2297 if (type && type_unknown_p (type))
2298 {
2299 error ("a statement expression is an insufficient context"
2300 " for overload resolution");
2301 TREE_TYPE (stmt_expr)((contains_struct_check ((stmt_expr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2301, __FUNCTION__))->typed.type)
= error_mark_nodeglobal_trees[TI_ERROR_MARK];
2302 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
2303 }
2304 else if (processing_template_declscope_chain->x_processing_template_decl)
2305 {
2306 expr = build_stmt (input_location, EXPR_STMT, expr);
2307 expr = add_stmt (expr);
2308 /* Mark the last statement so that we can recognize it as such at
2309 template-instantiation time. */
2310 EXPR_STMT_STMT_EXPR_RESULT (expr)((tree_not_check2 (((tree_check ((expr), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2310, __FUNCTION__, (EXPR_STMT)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2310, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_0)
= 1;
2311 }
2312 else if (VOID_TYPE_P (type)(((enum tree_code) (type)->base.code) == VOID_TYPE))
2313 {
2314 /* Just treat this like an ordinary statement. */
2315 expr = finish_expr_stmt (expr);
2316 }
2317 else
2318 {
2319 /* It actually has a value we need to deal with. First, force it
2320 to be an rvalue so that we won't need to build up a copy
2321 constructor call later when we try to assign it to something. */
2322 expr = force_rvalue (expr, tf_warning_or_error);
2323 if (error_operand_p (expr)((expr) == global_trees[TI_ERROR_MARK] || ((expr) && (
(contains_struct_check (((expr)), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2323, __FUNCTION__))->typed.type) == global_trees[TI_ERROR_MARK
]))
)
2324 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
2325
2326 /* Update for array-to-pointer decay. */
2327 type = TREE_TYPE (expr)((contains_struct_check ((expr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2327, __FUNCTION__))->typed.type)
;
2328
2329 /* Wrap it in a CLEANUP_POINT_EXPR and add it to the list like a
2330 normal statement, but don't convert to void or actually add
2331 the EXPR_STMT. */
2332 if (TREE_CODE (expr)((enum tree_code) (expr)->base.code) != CLEANUP_POINT_EXPR)
2333 expr = maybe_cleanup_point_expr (expr);
2334 add_stmt (expr);
2335 }
2336
2337 /* The type of the statement-expression is the type of the last
2338 expression. */
2339 TREE_TYPE (stmt_expr)((contains_struct_check ((stmt_expr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2339, __FUNCTION__))->typed.type)
= type;
2340 }
2341
2342 return stmt_expr;
2343}
2344
2345/* Finish a statement-expression. EXPR should be the value returned
2346 by the previous begin_stmt_expr. Returns an expression
2347 representing the statement-expression. */
2348
2349tree
2350finish_stmt_expr (tree stmt_expr, bool has_no_scope)
2351{
2352 tree type;
2353 tree result;
2354
2355 if (error_operand_p (stmt_expr)((stmt_expr) == global_trees[TI_ERROR_MARK] || ((stmt_expr) &&
((contains_struct_check (((stmt_expr)), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2355, __FUNCTION__))->typed.type) == global_trees[TI_ERROR_MARK
]))
)
2356 {
2357 pop_stmt_list (stmt_expr);
2358 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
2359 }
2360
2361 gcc_assert (TREE_CODE (stmt_expr) == STATEMENT_LIST)((void)(!(((enum tree_code) (stmt_expr)->base.code) == STATEMENT_LIST
) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2361, __FUNCTION__), 0 : 0))
;
2362
2363 type = TREE_TYPE (stmt_expr)((contains_struct_check ((stmt_expr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2363, __FUNCTION__))->typed.type)
;
2364 result = pop_stmt_list (stmt_expr);
2365 TREE_TYPE (result)((contains_struct_check ((result), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2365, __FUNCTION__))->typed.type)
= type;
2366
2367 if (processing_template_declscope_chain->x_processing_template_decl)
2368 {
2369 result = build_min (STMT_EXPR, type, result);
2370 TREE_SIDE_EFFECTS (result)((non_type_check ((result), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2370, __FUNCTION__))->base.side_effects_flag)
= 1;
2371 STMT_EXPR_NO_SCOPE (result)((tree_not_check2 (((tree_check ((result), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2371, __FUNCTION__, (STMT_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2371, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_0)
= has_no_scope;
2372 }
2373 else if (CLASS_TYPE_P (type)(((((enum tree_code) (type)->base.code)) == RECORD_TYPE ||
(((enum tree_code) (type)->base.code)) == UNION_TYPE) &&
((tree_class_check ((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2373, __FUNCTION__))->type_common.lang_flag_5))
)
2374 {
2375 /* Wrap the statement-expression in a TARGET_EXPR so that the
2376 temporary object created by the final expression is destroyed at
2377 the end of the full-expression containing the
2378 statement-expression. */
2379 result = force_target_expr (type, result, tf_warning_or_error);
2380 }
2381
2382 return result;
2383}
2384
2385/* Returns the expression which provides the value of STMT_EXPR. */
2386
2387tree
2388stmt_expr_value_expr (tree stmt_expr)
2389{
2390 tree t = STMT_EXPR_STMT (stmt_expr)(*((const_cast<tree*> (tree_operand_check (((tree_check
((stmt_expr), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2390, __FUNCTION__, (STMT_EXPR)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2390, __FUNCTION__)))))
;
2391
2392 if (TREE_CODE (t)((enum tree_code) (t)->base.code) == BIND_EXPR)
2393 t = BIND_EXPR_BODY (t)((*((const_cast<tree*> (tree_operand_check (((tree_check
((t), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2393, __FUNCTION__, (BIND_EXPR)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2393, __FUNCTION__))))))
;
2394
2395 if (TREE_CODE (t)((enum tree_code) (t)->base.code) == STATEMENT_LIST && STATEMENT_LIST_TAIL (t)((tree_check ((t), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2395, __FUNCTION__, (STATEMENT_LIST)))->stmt_list.tail)
)
2396 t = STATEMENT_LIST_TAIL (t)((tree_check ((t), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2396, __FUNCTION__, (STATEMENT_LIST)))->stmt_list.tail)
->stmt;
2397
2398 if (TREE_CODE (t)((enum tree_code) (t)->base.code) == EXPR_STMT)
2399 t = EXPR_STMT_EXPR (t)(*((const_cast<tree*> (tree_operand_check (((tree_check
((t), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2399, __FUNCTION__, (EXPR_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2399, __FUNCTION__)))))
;
2400
2401 return t;
2402}
2403
2404/* Return TRUE iff EXPR_STMT is an empty list of
2405 expression statements. */
2406
2407bool
2408empty_expr_stmt_p (tree expr_stmt)
2409{
2410 tree body = NULL_TREE(tree) __null;
2411
2412 if (expr_stmt == void_nodeglobal_trees[TI_VOID])
2413 return true;
2414
2415 if (expr_stmt)
2416 {
2417 if (TREE_CODE (expr_stmt)((enum tree_code) (expr_stmt)->base.code) == EXPR_STMT)
2418 body = EXPR_STMT_EXPR (expr_stmt)(*((const_cast<tree*> (tree_operand_check (((tree_check
((expr_stmt), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2418, __FUNCTION__, (EXPR_STMT)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2418, __FUNCTION__)))))
;
2419 else if (TREE_CODE (expr_stmt)((enum tree_code) (expr_stmt)->base.code) == STATEMENT_LIST)
2420 body = expr_stmt;
2421 }
2422
2423 if (body)
2424 {
2425 if (TREE_CODE (body)((enum tree_code) (body)->base.code) == STATEMENT_LIST)
2426 return tsi_end_p (tsi_start (body));
2427 else
2428 return empty_expr_stmt_p (body);
2429 }
2430 return false;
2431}
2432
2433/* Perform Koenig lookup. FN_EXPR is the postfix-expression representing
2434 the function (or functions) to call; ARGS are the arguments to the
2435 call. Returns the functions to be considered by overload resolution. */
2436
2437cp_expr
2438perform_koenig_lookup (cp_expr fn_expr, vec<tree, va_gc> *args,
2439 tsubst_flags_t complain)
2440{
2441 tree identifier = NULL_TREE(tree) __null;
2442 tree functions = NULL_TREE(tree) __null;
2443 tree tmpl_args = NULL_TREE(tree) __null;
2444 bool template_id = false;
2445 location_t loc = fn_expr.get_location ();
2446 tree fn = fn_expr.get_value ();
2447
2448 STRIP_ANY_LOCATION_WRAPPER (fn)(fn) = tree_strip_any_location_wrapper ((const_cast<union tree_node
*> (((fn)))))
;
2449
2450 if (TREE_CODE (fn)((enum tree_code) (fn)->base.code) == TEMPLATE_ID_EXPR)
2451 {
2452 /* Use a separate flag to handle null args. */
2453 template_id = true;
2454 tmpl_args = TREE_OPERAND (fn, 1)(*((const_cast<tree*> (tree_operand_check ((fn), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2454, __FUNCTION__)))))
;
2455 fn = TREE_OPERAND (fn, 0)(*((const_cast<tree*> (tree_operand_check ((fn), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2455, __FUNCTION__)))))
;
2456 }
2457
2458 /* Find the name of the overloaded function. */
2459 if (identifier_p (fn))
2460 identifier = fn;
2461 else
2462 {
2463 functions = fn;
2464 identifier = OVL_NAME (functions)((contains_struct_check ((ovl_first (functions)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2464, __FUNCTION__))->decl_minimal.name)
;
2465 }
2466
2467 /* A call to a namespace-scope function using an unqualified name.
2468
2469 Do Koenig lookup -- unless any of the arguments are
2470 type-dependent. */
2471 if (!any_type_dependent_arguments_p (args)
2472 && !any_dependent_template_arguments_p (tmpl_args))
2473 {
2474 fn = lookup_arg_dependent (identifier, functions, args);
2475 if (!fn)
2476 {
2477 /* The unqualified name could not be resolved. */
2478 if (complain & tf_error)
2479 fn = unqualified_fn_lookup_error (cp_expr (identifier, loc));
2480 else
2481 fn = identifier;
2482 }
2483 }
2484
2485 if (fn && template_id && fn != error_mark_nodeglobal_trees[TI_ERROR_MARK])
2486 fn = build2 (TEMPLATE_ID_EXPR, unknown_type_nodecp_global_trees[CPTI_UNKNOWN_TYPE], fn, tmpl_args);
2487
2488 return cp_expr (fn, loc);
2489}
2490
2491/* Generate an expression for `FN (ARGS)'. This may change the
2492 contents of ARGS.
2493
2494 If DISALLOW_VIRTUAL is true, the call to FN will be not generated
2495 as a virtual call, even if FN is virtual. (This flag is set when
2496 encountering an expression where the function name is explicitly
2497 qualified. For example a call to `X::f' never generates a virtual
2498 call.)
2499
2500 Returns code for the call. */
2501
2502tree
2503finish_call_expr (tree fn, vec<tree, va_gc> **args, bool disallow_virtual,
2504 bool koenig_p, tsubst_flags_t complain)
2505{
2506 tree result;
2507 tree orig_fn;
2508 vec<tree, va_gc> *orig_args = *args;
2509
2510 if (fn == error_mark_nodeglobal_trees[TI_ERROR_MARK])
2511 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
2512
2513 gcc_assert (!TYPE_P (fn))((void)(!(!(tree_code_type[(int) (((enum tree_code) (fn)->
base.code))] == tcc_type)) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2513, __FUNCTION__), 0 : 0))
;
2514
2515 /* If FN may be a FUNCTION_DECL obfuscated by force_paren_expr, undo
2516 it so that we can tell this is a call to a known function. */
2517 fn = maybe_undo_parenthesized_ref (fn);
2518
2519 STRIP_ANY_LOCATION_WRAPPER (fn)(fn) = tree_strip_any_location_wrapper ((const_cast<union tree_node
*> (((fn)))))
;
2520
2521 orig_fn = fn;
2522
2523 if (processing_template_declscope_chain->x_processing_template_decl)
2524 {
2525 /* If FN is a local extern declaration or set thereof, look them up
2526 again at instantiation time. */
2527 if (is_overloaded_fn (fn))
2528 {
2529 tree ifn = get_first_fn (fn);
2530 if (TREE_CODE (ifn)((enum tree_code) (ifn)->base.code) == FUNCTION_DECL
2531 && DECL_LOCAL_DECL_P (ifn)((contains_struct_check (((tree_check2 ((ifn), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2531, __FUNCTION__, (VAR_DECL), (FUNCTION_DECL)))), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2531, __FUNCTION__))->decl_common.lang_flag_0)
)
2532 orig_fn = DECL_NAME (ifn)((contains_struct_check ((ifn), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2532, __FUNCTION__))->decl_minimal.name)
;
2533 }
2534
2535 /* If the call expression is dependent, build a CALL_EXPR node
2536 with no type; type_dependent_expression_p recognizes
2537 expressions with no type as being dependent. */
2538 if (type_dependent_expression_p (fn)
2539 || any_type_dependent_arguments_p (*args))
2540 {
2541 result = build_min_nt_call_vec (orig_fn, *args);
2542 SET_EXPR_LOCATION (result, cp_expr_loc_or_input_loc (fn))(expr_check (((result)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2542, __FUNCTION__))->exp.locus = (cp_expr_loc_or_input_loc
(fn))
;
2543 KOENIG_LOOKUP_P (result)((tree_not_check2 (((tree_check ((result), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2543, __FUNCTION__, (CALL_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2543, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_0)
= koenig_p;
2544 if (is_overloaded_fn (fn))
2545 fn = get_fns (fn);
2546
2547 if (cfun(cfun + 0))
2548 {
2549 bool abnormal = true;
2550 for (lkp_iterator iter (fn); abnormal && iter; ++iter)
2551 {
2552 tree fndecl = STRIP_TEMPLATE (*iter)(((enum tree_code) (*iter)->base.code) == TEMPLATE_DECL ? (
(struct tree_template_decl *)(const_cast<union tree_node *
> ((((tree_check ((*iter), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2552, __FUNCTION__, (TEMPLATE_DECL))))))))->result : *iter
)
;
2553 if (TREE_CODE (fndecl)((enum tree_code) (fndecl)->base.code) != FUNCTION_DECL
2554 || !TREE_THIS_VOLATILE (fndecl)((fndecl)->base.volatile_flag))
2555 abnormal = false;
2556 }
2557 /* FIXME: Stop warning about falling off end of non-void
2558 function. But this is wrong. Even if we only see
2559 no-return fns at this point, we could select a
2560 future-defined return fn during instantiation. Or
2561 vice-versa. */
2562 if (abnormal)
2563 current_function_returns_abnormally((cfun + 0)->language)->returns_abnormally = 1;
2564 }
2565 return result;
2566 }
2567 orig_args = make_tree_vector_copy (*args);
2568 if (!BASELINK_P (fn)(((enum tree_code) (fn)->base.code) == BASELINK)
2569 && TREE_CODE (fn)((enum tree_code) (fn)->base.code) != PSEUDO_DTOR_EXPR
2570 && TREE_TYPE (fn)((contains_struct_check ((fn), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2570, __FUNCTION__))->typed.type)
!= unknown_type_nodecp_global_trees[CPTI_UNKNOWN_TYPE])
2571 fn = build_non_dependent_expr (fn);
2572 make_args_non_dependent (*args);
2573 }
2574
2575 if (TREE_CODE (fn)((enum tree_code) (fn)->base.code) == COMPONENT_REF)
2576 {
2577 tree member = TREE_OPERAND (fn, 1)(*((const_cast<tree*> (tree_operand_check ((fn), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2577, __FUNCTION__)))))
;
2578 if (BASELINK_P (member)(((enum tree_code) (member)->base.code) == BASELINK))
2579 {
2580 tree object = TREE_OPERAND (fn, 0)(*((const_cast<tree*> (tree_operand_check ((fn), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2580, __FUNCTION__)))))
;
2581 return build_new_method_call (object, member,
2582 args, NULL_TREE(tree) __null,
2583 (disallow_virtual
2584 ? LOOKUP_NORMAL((1 << 0)) | LOOKUP_NONVIRTUAL(1 << 1)
2585 : LOOKUP_NORMAL((1 << 0))),
2586 /*fn_p=*/NULL__null,
2587 complain);
2588 }
2589 }
2590
2591 /* Per 13.3.1.1, '(&f)(...)' is the same as '(f)(...)'. */
2592 if (TREE_CODE (fn)((enum tree_code) (fn)->base.code) == ADDR_EXPR
2593 && TREE_CODE (TREE_OPERAND (fn, 0))((enum tree_code) ((*((const_cast<tree*> (tree_operand_check
((fn), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2593, __FUNCTION__))))))->base.code)
== OVERLOAD)
2594 fn = TREE_OPERAND (fn, 0)(*((const_cast<tree*> (tree_operand_check ((fn), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2594, __FUNCTION__)))))
;
2595
2596 if (is_overloaded_fn (fn))
2597 fn = baselink_for_fns (fn);
2598
2599 result = NULL_TREE(tree) __null;
2600 if (BASELINK_P (fn)(((enum tree_code) (fn)->base.code) == BASELINK))
2601 {
2602 tree object;
2603
2604 /* A call to a member function. From [over.call.func]:
2605
2606 If the keyword this is in scope and refers to the class of
2607 that member function, or a derived class thereof, then the
2608 function call is transformed into a qualified function call
2609 using (*this) as the postfix-expression to the left of the
2610 . operator.... [Otherwise] a contrived object of type T
2611 becomes the implied object argument.
2612
2613 In this situation:
2614
2615 struct A { void f(); };
2616 struct B : public A {};
2617 struct C : public A { void g() { B::f(); }};
2618
2619 "the class of that member function" refers to `A'. But 11.2
2620 [class.access.base] says that we need to convert 'this' to B* as
2621 part of the access, so we pass 'B' to maybe_dummy_object. */
2622
2623 if (DECL_MAYBE_IN_CHARGE_CONSTRUCTOR_P (get_first_fn (fn))(((contains_struct_check ((get_first_fn (fn)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2623, __FUNCTION__))->decl_minimal.name) == cp_global_trees
[CPTI_CTOR_IDENTIFIER])
)
2624 {
2625 /* A constructor call always uses a dummy object. (This constructor
2626 call which has the form A::A () is actually invalid and we are
2627 going to reject it later in build_new_method_call.) */
2628 object = build_dummy_object (BINFO_TYPE (BASELINK_ACCESS_BINFO (fn))((contains_struct_check (((tree_check (((((struct tree_baselink
*) (tree_check ((fn), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2628, __FUNCTION__, (BASELINK))))->access_binfo)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2628, __FUNCTION__, (TREE_BINFO)))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2628, __FUNCTION__))->typed.type)
);
2629 }
2630 else
2631 object = maybe_dummy_object (BINFO_TYPE (BASELINK_ACCESS_BINFO (fn))((contains_struct_check (((tree_check (((((struct tree_baselink
*) (tree_check ((fn), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2631, __FUNCTION__, (BASELINK))))->access_binfo)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2631, __FUNCTION__, (TREE_BINFO)))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2631, __FUNCTION__))->typed.type)
,
2632 NULL__null);
2633
2634 result = build_new_method_call (object, fn, args, NULL_TREE(tree) __null,
2635 (disallow_virtual
2636 ? LOOKUP_NORMAL((1 << 0))|LOOKUP_NONVIRTUAL(1 << 1)
2637 : LOOKUP_NORMAL((1 << 0))),
2638 /*fn_p=*/NULL__null,
2639 complain);
2640 }
2641 else if (concept_check_p (fn))
2642 {
2643 /* FN is actually a template-id referring to a concept definition. */
2644 tree id = unpack_concept_check (fn);
2645 tree tmpl = TREE_OPERAND (id, 0)(*((const_cast<tree*> (tree_operand_check ((id), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2645, __FUNCTION__)))))
;
2646 tree args = TREE_OPERAND (id, 1)(*((const_cast<tree*> (tree_operand_check ((id), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2646, __FUNCTION__)))))
;
2647
2648 if (!function_concept_p (tmpl))
2649 {
2650 error_at (EXPR_LOC_OR_LOC (fn, input_location)((((IS_ADHOC_LOC (((((fn)) && ((tree_code_type[(int) (
((enum tree_code) ((fn))->base.code))]) >= tcc_reference
&& (tree_code_type[(int) (((enum tree_code) ((fn))->
base.code))]) <= tcc_expression)) ? (fn)->exp.locus : (
(location_t) 0)))) ? get_location_from_adhoc_loc (line_table,
((((fn)) && ((tree_code_type[(int) (((enum tree_code
) ((fn))->base.code))]) >= tcc_reference && (tree_code_type
[(int) (((enum tree_code) ((fn))->base.code))]) <= tcc_expression
)) ? (fn)->exp.locus : ((location_t) 0))) : (((((fn)) &&
((tree_code_type[(int) (((enum tree_code) ((fn))->base.code
))]) >= tcc_reference && (tree_code_type[(int) (((
enum tree_code) ((fn))->base.code))]) <= tcc_expression
)) ? (fn)->exp.locus : ((location_t) 0)))) != ((location_t
) 0)) ? (fn)->exp.locus : (input_location))
,
2651 "cannot call a concept as a function");
2652 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
2653 }
2654
2655 /* Ensure the result is wrapped as a call expression. */
2656 result = build_concept_check (tmpl, args, tf_warning_or_error);
2657 }
2658 else if (is_overloaded_fn (fn))
2659 {
2660 /* If the function is an overloaded builtin, resolve it. */
2661 if (TREE_CODE (fn)((enum tree_code) (fn)->base.code) == FUNCTION_DECL
2662 && (DECL_BUILT_IN_CLASS (fn)((built_in_class) (tree_check ((fn), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2662, __FUNCTION__, (FUNCTION_DECL)))->function_decl.built_in_class
)
== BUILT_IN_NORMAL
2663 || DECL_BUILT_IN_CLASS (fn)((built_in_class) (tree_check ((fn), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2663, __FUNCTION__, (FUNCTION_DECL)))->function_decl.built_in_class
)
== BUILT_IN_MD))
2664 result = resolve_overloaded_builtin (input_location, fn, *args);
2665
2666 if (!result)
2667 {
2668 if (warn_sizeof_pointer_memaccessglobal_options.x_warn_sizeof_pointer_memaccess
2669 && (complain & tf_warning)
2670 && !vec_safe_is_empty (*args)
2671 && !processing_template_declscope_chain->x_processing_template_decl)
2672 {
2673 location_t sizeof_arg_loc[3];
2674 tree sizeof_arg[3];
2675 unsigned int i;
2676 for (i = 0; i < 3; i++)
2677 {
2678 tree t;
2679
2680 sizeof_arg_loc[i] = UNKNOWN_LOCATION((location_t) 0);
2681 sizeof_arg[i] = NULL_TREE(tree) __null;
2682 if (i >= (*args)->length ())
2683 continue;
2684 t = (**args)[i];
2685 if (TREE_CODE (t)((enum tree_code) (t)->base.code) != SIZEOF_EXPR)
2686 continue;
2687 if (SIZEOF_EXPR_TYPE_P (t)((tree_not_check2 (((tree_check ((t), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2687, __FUNCTION__, (SIZEOF_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2687, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_0)
)
2688 sizeof_arg[i] = TREE_TYPE (TREE_OPERAND (t, 0))((contains_struct_check (((*((const_cast<tree*> (tree_operand_check
((t), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2688, __FUNCTION__)))))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2688, __FUNCTION__))->typed.type)
;
2689 else
2690 sizeof_arg[i] = TREE_OPERAND (t, 0)(*((const_cast<tree*> (tree_operand_check ((t), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2690, __FUNCTION__)))))
;
2691 sizeof_arg_loc[i] = EXPR_LOCATION (t)((((t)) && ((tree_code_type[(int) (((enum tree_code) (
(t))->base.code))]) >= tcc_reference && (tree_code_type
[(int) (((enum tree_code) ((t))->base.code))]) <= tcc_expression
)) ? (t)->exp.locus : ((location_t) 0))
;
2692 }
2693 sizeof_pointer_memaccess_warning
2694 (sizeof_arg_loc, fn, *args,
2695 sizeof_arg, same_type_ignoring_top_level_qualifiers_p);
2696 }
2697
2698 if ((complain & tf_warning)
2699 && TREE_CODE (fn)((enum tree_code) (fn)->base.code) == FUNCTION_DECL
2700 && fndecl_built_in_p (fn, BUILT_IN_MEMSET)
2701 && vec_safe_length (*args) == 3
2702 && !any_type_dependent_arguments_p (*args))
2703 {
2704 tree arg0 = (*orig_args)[0];
2705 tree arg1 = (*orig_args)[1];
2706 tree arg2 = (*orig_args)[2];
2707 int literal_mask = ((literal_integer_zerop (arg1) << 1)
2708 | (literal_integer_zerop (arg2) << 2));
2709 warn_for_memset (input_location, arg0, arg2, literal_mask);
2710 }
2711
2712 /* A call to a namespace-scope function. */
2713 result = build_new_function_call (fn, args, complain);
2714 }
2715 }
2716 else if (TREE_CODE (fn)((enum tree_code) (fn)->base.code) == PSEUDO_DTOR_EXPR)
2717 {
2718 if (!vec_safe_is_empty (*args))
2719 error ("arguments to destructor are not allowed");
2720 /* C++20/DR: If the postfix-expression names a pseudo-destructor (in
2721 which case the postfix-expression is a possibly-parenthesized class
2722 member access), the function call destroys the object of scalar type
2723 denoted by the object expression of the class member access. */
2724 tree ob = TREE_OPERAND (fn, 0)(*((const_cast<tree*> (tree_operand_check ((fn), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2724, __FUNCTION__)))))
;
2725 if (obvalue_p (ob))
2726 result = build_trivial_dtor_call (ob, true);
2727 else
2728 /* No location to clobber. */
2729 result = convert_to_void (ob, ICV_STATEMENT, complain);
2730 }
2731 else if (CLASS_TYPE_P (TREE_TYPE (fn))(((((enum tree_code) (((contains_struct_check ((fn), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2731, __FUNCTION__))->typed.type))->base.code)) == RECORD_TYPE
|| (((enum tree_code) (((contains_struct_check ((fn), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2731, __FUNCTION__))->typed.type))->base.code)) == UNION_TYPE
) && ((tree_class_check ((((contains_struct_check ((fn
), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2731, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2731, __FUNCTION__))->type_common.lang_flag_5))
)
2732 /* If the "function" is really an object of class type, it might
2733 have an overloaded `operator ()'. */
2734 result = build_op_call (fn, args, complain);
2735
2736 if (!result)
2737 /* A call where the function is unknown. */
2738 result = cp_build_function_call_vec (fn, args, complain);
2739
2740 if (processing_template_declscope_chain->x_processing_template_decl && result != error_mark_nodeglobal_trees[TI_ERROR_MARK])
2741 {
2742 if (INDIRECT_REF_P (result)(((enum tree_code) (result)->base.code) == INDIRECT_REF))
2743 result = TREE_OPERAND (result, 0)(*((const_cast<tree*> (tree_operand_check ((result), (0
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2743, __FUNCTION__)))))
;
2744 result = build_call_vec (TREE_TYPE (result)((contains_struct_check ((result), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2744, __FUNCTION__))->typed.type)
, orig_fn, orig_args);
2745 SET_EXPR_LOCATION (result, input_location)(expr_check (((result)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2745, __FUNCTION__))->exp.locus = (input_location)
;
2746 KOENIG_LOOKUP_P (result)((tree_not_check2 (((tree_check ((result), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2746, __FUNCTION__, (CALL_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2746, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_0)
= koenig_p;
2747 release_tree_vector (orig_args);
2748 result = convert_from_reference (result);
2749 }
2750
2751 return result;
2752}
2753
2754/* Finish a call to a postfix increment or decrement or EXPR. (Which
2755 is indicated by CODE, which should be POSTINCREMENT_EXPR or
2756 POSTDECREMENT_EXPR.) */
2757
2758cp_expr
2759finish_increment_expr (cp_expr expr, enum tree_code code)
2760{
2761 /* input_location holds the location of the trailing operator token.
2762 Build a location of the form:
2763 expr++
2764 ~~~~^~
2765 with the caret at the operator token, ranging from the start
2766 of EXPR to the end of the operator token. */
2767 location_t combined_loc = make_location (input_location,
2768 expr.get_start (),
2769 get_finish (input_location));
2770 cp_expr result = build_x_unary_op (combined_loc, code, expr,
2771 tf_warning_or_error);
2772 /* TODO: build_x_unary_op doesn't honor the location, so set it here. */
2773 result.set_location (combined_loc);
2774 return result;
2775}
2776
2777/* Finish a use of `this'. Returns an expression for `this'. */
2778
2779tree
2780finish_this_expr (void)
2781{
2782 tree result = NULL_TREE(tree) __null;
2783
2784 if (current_class_ptr(*((cfun + 0) && ((cfun + 0)->language) ? &((cfun
+ 0)->language)->x_current_class_ptr : &scope_chain
->x_current_class_ptr))
)
2785 {
2786 tree type = TREE_TYPE (current_class_ref)((contains_struct_check (((*((cfun + 0) && ((cfun + 0
)->language) ? &((cfun + 0)->language)->x_current_class_ref
: &scope_chain->x_current_class_ref))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2786, __FUNCTION__))->typed.type)
;
2787
2788 /* In a lambda expression, 'this' refers to the captured 'this'. */
2789 if (LAMBDA_TYPE_P (type)(((enum tree_code) (type)->base.code) == RECORD_TYPE &&
((((tree_class_check ((((tree_class_check ((type), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check ((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check ((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__))->type_common.name))) && ((tree_check
((((((tree_class_check ((((tree_class_check ((type), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check ((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check ((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__))->type_common.name)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2789, __FUNCTION__, (IDENTIFIER_NODE)))->base.protected_flag
))
)
2790 result = lambda_expr_this_capture (CLASSTYPE_LAMBDA_EXPR (type)((((tree_class_check ((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2790, __FUNCTION__))->type_with_lang_specific.lang_specific
))->lambda_expr)
, true);
2791 else
2792 result = current_class_ptr(*((cfun + 0) && ((cfun + 0)->language) ? &((cfun
+ 0)->language)->x_current_class_ptr : &scope_chain
->x_current_class_ptr))
;
2793 }
2794
2795 if (result)
2796 /* The keyword 'this' is a prvalue expression. */
2797 return rvalue (result);
2798
2799 tree fn = current_nonlambda_function ();
2800 if (fn && DECL_STATIC_FUNCTION_P (fn)(__extension__ ({ struct lang_decl *lt = ((contains_struct_check
(((((enum tree_code) (fn)->base.code) == TEMPLATE_DECL ? (
(struct tree_template_decl *)(const_cast<union tree_node *
> ((((tree_check ((fn), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2800, __FUNCTION__, (TEMPLATE_DECL))))))))->result : fn)
), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2800, __FUNCTION__))->decl_common.lang_specific); if (!(
((enum tree_code) (fn)->base.code) == FUNCTION_DECL || (((
enum tree_code) (fn)->base.code) == TEMPLATE_DECL &&
((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((fn), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2800, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((fn),
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2800, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)) || lt->u.base.selector != lds_fn
) lang_check_failed ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2800, __FUNCTION__); &lt->u.fn; })->static_function
)
)
2801 error ("%<this%> is unavailable for static member functions");
2802 else if (fn)
2803 error ("invalid use of %<this%> in non-member function");
2804 else
2805 error ("invalid use of %<this%> at top level");
2806 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
2807}
2808
2809/* Finish a pseudo-destructor expression. If SCOPE is NULL, the
2810 expression was of the form `OBJECT.~DESTRUCTOR' where DESTRUCTOR is
2811 the TYPE for the type given. If SCOPE is non-NULL, the expression
2812 was of the form `OBJECT.SCOPE::~DESTRUCTOR'. */
2813
2814tree
2815finish_pseudo_destructor_expr (tree object, tree scope, tree destructor,
2816 location_t loc)
2817{
2818 if (object == error_mark_nodeglobal_trees[TI_ERROR_MARK] || destructor == error_mark_nodeglobal_trees[TI_ERROR_MARK])
2819 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
2820
2821 gcc_assert (TYPE_P (destructor))((void)(!((tree_code_type[(int) (((enum tree_code) (destructor
)->base.code))] == tcc_type)) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2821, __FUNCTION__), 0 : 0))
;
2822
2823 if (!processing_template_declscope_chain->x_processing_template_decl)
2824 {
2825 if (scope == error_mark_nodeglobal_trees[TI_ERROR_MARK])
2826 {
2827 error_at (loc, "invalid qualifying scope in pseudo-destructor name");
2828 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
2829 }
2830 if (is_auto (destructor))
2831 destructor = TREE_TYPE (object)((contains_struct_check ((object), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2831, __FUNCTION__))->typed.type)
;
2832 if (scope && TYPE_P (scope)(tree_code_type[(int) (((enum tree_code) (scope)->base.code
))] == tcc_type)
&& !check_dtor_name (scope, destructor))
2833 {
2834 error_at (loc,
2835 "qualified type %qT does not match destructor name ~%qT",
2836 scope, destructor);
2837 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
2838 }
2839
2840
2841 /* [expr.pseudo] says both:
2842
2843 The type designated by the pseudo-destructor-name shall be
2844 the same as the object type.
2845
2846 and:
2847
2848 The cv-unqualified versions of the object type and of the
2849 type designated by the pseudo-destructor-name shall be the
2850 same type.
2851
2852 We implement the more generous second sentence, since that is
2853 what most other compilers do. */
2854 if (!same_type_ignoring_top_level_qualifiers_p (TREE_TYPE (object)((contains_struct_check ((object), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2854, __FUNCTION__))->typed.type)
,
2855 destructor))
2856 {
2857 error_at (loc, "%qE is not of type %qT", object, destructor);
2858 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
2859 }
2860 }
2861
2862 tree type = (type_dependent_expression_p (object)
2863 ? NULL_TREE(tree) __null : void_type_nodeglobal_trees[TI_VOID_TYPE]);
2864
2865 return build3_loc (loc, PSEUDO_DTOR_EXPR, type, object,
2866 scope, destructor);
2867}
2868
2869/* Finish an expression of the form CODE EXPR. */
2870
2871cp_expr
2872finish_unary_op_expr (location_t op_loc, enum tree_code code, cp_expr expr,
2873 tsubst_flags_t complain)
2874{
2875 /* Build a location of the form:
2876 ++expr
2877 ^~~~~~
2878 with the caret at the operator token, ranging from the start
2879 of the operator token to the end of EXPR. */
2880 location_t combined_loc = make_location (op_loc,
2881 op_loc, expr.get_finish ());
2882 cp_expr result = build_x_unary_op (combined_loc, code, expr, complain);
2883 /* TODO: build_x_unary_op doesn't always honor the location. */
2884 result.set_location (combined_loc);
2885
2886 if (result == error_mark_nodeglobal_trees[TI_ERROR_MARK])
2887 return result;
2888
2889 if (!(complain & tf_warning))
2890 return result;
2891
2892 tree result_ovl = result;
2893 tree expr_ovl = expr;
2894
2895 if (!processing_template_declscope_chain->x_processing_template_decl)
2896 expr_ovl = cp_fully_fold (expr_ovl);
2897
2898 if (!CONSTANT_CLASS_P (expr_ovl)(tree_code_type[(int) (((enum tree_code) (expr_ovl)->base.
code))] == tcc_constant)
2899 || TREE_OVERFLOW_P (expr_ovl)((tree_code_type[(int) (((enum tree_code) (expr_ovl)->base
.code))] == tcc_constant) && ((tree_class_check ((expr_ovl
), (tcc_constant), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2899, __FUNCTION__))->base.public_flag))
)
2900 return result;
2901
2902 if (!processing_template_declscope_chain->x_processing_template_decl)
2903 result_ovl = cp_fully_fold (result_ovl);
2904
2905 if (CONSTANT_CLASS_P (result_ovl)(tree_code_type[(int) (((enum tree_code) (result_ovl)->base
.code))] == tcc_constant)
&& TREE_OVERFLOW_P (result_ovl)((tree_code_type[(int) (((enum tree_code) (result_ovl)->base
.code))] == tcc_constant) && ((tree_class_check ((result_ovl
), (tcc_constant), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2905, __FUNCTION__))->base.public_flag))
)
2906 overflow_warning (combined_loc, result_ovl);
2907
2908 return result;
2909}
2910
2911/* Finish a compound-literal expression or C++11 functional cast with aggregate
2912 initializer. TYPE is the type to which the CONSTRUCTOR in COMPOUND_LITERAL
2913 is being cast. */
2914
2915tree
2916finish_compound_literal (tree type, tree compound_literal,
2917 tsubst_flags_t complain,
2918 fcl_t fcl_context)
2919{
2920 if (type == error_mark_nodeglobal_trees[TI_ERROR_MARK])
2921 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
2922
2923 if (TYPE_REF_P (type)(((enum tree_code) (type)->base.code) == REFERENCE_TYPE))
2924 {
2925 compound_literal
2926 = finish_compound_literal (TREE_TYPE (type)((contains_struct_check ((type), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2926, __FUNCTION__))->typed.type)
, compound_literal,
2927 complain, fcl_context);
2928 /* The prvalue is then used to direct-initialize the reference. */
2929 tree r = (perform_implicit_conversion_flags
2930 (type, compound_literal, complain, LOOKUP_NORMAL((1 << 0))));
2931 return convert_from_reference (r);
2932 }
2933
2934 if (!TYPE_OBJ_P (type)(!(((enum tree_code) (type)->base.code) == REFERENCE_TYPE)
&& !(((enum tree_code) (type)->base.code) == VOID_TYPE
) && !(((enum tree_code) (type)->base.code) == FUNCTION_TYPE
|| ((enum tree_code) (type)->base.code) == METHOD_TYPE))
)
2935 {
2936 if (complain & tf_error)
2937 error ("compound literal of non-object type %qT", type);
2938 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
2939 }
2940
2941 if (tree anode = type_uses_auto (type))
2942 if (CLASS_PLACEHOLDER_TEMPLATE (anode)(((contains_struct_check ((((tree_class_check (((tree_check (
(anode), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2942, __FUNCTION__, (TEMPLATE_TYPE_PARM)))), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2942, __FUNCTION__))->type_common.name)), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2942, __FUNCTION__))->decl_common.initial))
)
2943 {
2944 type = do_auto_deduction (type, compound_literal, anode, complain,
2945 adc_variable_type);
2946 if (type == error_mark_nodeglobal_trees[TI_ERROR_MARK])
2947 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
2948 }
2949
2950 /* Used to hold a copy of the compound literal in a template. */
2951 tree orig_cl = NULL_TREE(tree) __null;
2952
2953 if (processing_template_declscope_chain->x_processing_template_decl)
2954 {
2955 const bool dependent_p
2956 = (instantiation_dependent_expression_p (compound_literal)
2957 || dependent_type_p (type));
2958 if (dependent_p)
2959 /* We're about to return, no need to copy. */
2960 orig_cl = compound_literal;
2961 else
2962 /* We're going to need a copy. */
2963 orig_cl = unshare_constructor (compound_literal);
2964 TREE_TYPE (orig_cl)((contains_struct_check ((orig_cl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2964, __FUNCTION__))->typed.type)
= type;
2965 /* Mark the expression as a compound literal. */
2966 TREE_HAS_CONSTRUCTOR (orig_cl)(((tree_not_check2 ((orig_cl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2966, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_4))
= 1;
2967 /* And as instantiation-dependent. */
2968 CONSTRUCTOR_IS_DEPENDENT (orig_cl)(((tree_not_check2 (((tree_check ((orig_cl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2968, __FUNCTION__, (CONSTRUCTOR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2968, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_1))
= dependent_p;
2969 if (fcl_context == fcl_c99)
2970 CONSTRUCTOR_C99_COMPOUND_LITERAL (orig_cl)(((tree_not_check2 (((tree_check ((orig_cl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2970, __FUNCTION__, (CONSTRUCTOR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2970, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_3))
= 1;
2971 /* If the compound literal is dependent, we're done for now. */
2972 if (dependent_p)
2973 return orig_cl;
2974 /* Otherwise, do go on to e.g. check narrowing. */
2975 }
2976
2977 type = complete_type (type);
2978
2979 if (TYPE_NON_AGGREGATE_CLASS (type)((((((enum tree_code) (type)->base.code)) == RECORD_TYPE ||
(((enum tree_code) (type)->base.code)) == UNION_TYPE) &&
((tree_class_check ((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2979, __FUNCTION__))->type_common.lang_flag_5)) &&
((((tree_class_check ((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2979, __FUNCTION__))->type_with_lang_specific.lang_specific
))->non_aggregate))
)
2980 {
2981 /* Trying to deal with a CONSTRUCTOR instead of a TREE_LIST
2982 everywhere that deals with function arguments would be a pain, so
2983 just wrap it in a TREE_LIST. The parser set a flag so we know
2984 that it came from T{} rather than T({}). */
2985 CONSTRUCTOR_IS_DIRECT_INIT (compound_literal)(((tree_not_check2 (((tree_check ((compound_literal), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2985, __FUNCTION__, (CONSTRUCTOR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2985, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_0))
= 1;
2986 compound_literal = build_tree_list (NULL_TREE(tree) __null, compound_literal);
2987 return build_functional_cast (input_location, type,
2988 compound_literal, complain);
2989 }
2990
2991 if (TREE_CODE (type)((enum tree_code) (type)->base.code) == ARRAY_TYPE
2992 && check_array_initializer (NULL_TREE(tree) __null, type, compound_literal))
2993 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
2994 compound_literal = reshape_init (type, compound_literal, complain);
2995 if (SCALAR_TYPE_P (type)((((enum tree_code) (type)->base.code) == OFFSET_TYPE) || (
(enum tree_code) (type)->base.code) == ENUMERAL_TYPE || ((
((enum tree_code) (type)->base.code) == BOOLEAN_TYPE || ((
enum tree_code) (type)->base.code) == INTEGER_TYPE) || ((enum
tree_code) (type)->base.code) == REAL_TYPE || ((enum tree_code
) (type)->base.code) == COMPLEX_TYPE) || (((enum tree_code
) (type)->base.code) == POINTER_TYPE) || (((enum tree_code
) (type)->base.code) == RECORD_TYPE && (((tree_class_check
(((tree_check ((type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2995, __FUNCTION__, (RECORD_TYPE)))), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2995, __FUNCTION__))->type_common.lang_flag_2))) || (((enum
tree_code) (type)->base.code) == NULLPTR_TYPE))
2996 && !BRACE_ENCLOSED_INITIALIZER_P (compound_literal)(((enum tree_code) (compound_literal)->base.code) == CONSTRUCTOR
&& ((contains_struct_check ((compound_literal), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 2996, __FUNCTION__))->typed.type) == cp_global_trees[CPTI_INIT_LIST_TYPE
])
)
2997 {
2998 tree t = instantiate_non_dependent_expr_sfinae (compound_literal,
2999 complain);
3000 if (!check_narrowing (type, t, complain))
3001 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3002 }
3003 if (TREE_CODE (type)((enum tree_code) (type)->base.code) == ARRAY_TYPE
3004 && TYPE_DOMAIN (type)((tree_check ((type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3004, __FUNCTION__, (ARRAY_TYPE)))->type_non_common.values
)
== NULL_TREE(tree) __null)
3005 {
3006 cp_complete_array_type_or_error (&type, compound_literal,
3007 false, complain);
3008 if (type == error_mark_nodeglobal_trees[TI_ERROR_MARK])
3009 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3010 }
3011 compound_literal = digest_init_flags (type, compound_literal,
3012 LOOKUP_NORMAL((1 << 0)) | LOOKUP_NO_NARROWING(((1 << 6) << 1) << 1),
3013 complain);
3014 if (compound_literal == error_mark_nodeglobal_trees[TI_ERROR_MARK])
3015 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3016
3017 /* If we're in a template, return the original compound literal. */
3018 if (orig_cl)
3019 return orig_cl;
3020
3021 if (TREE_CODE (compound_literal)((enum tree_code) (compound_literal)->base.code) == CONSTRUCTOR)
3022 {
3023 TREE_HAS_CONSTRUCTOR (compound_literal)(((tree_not_check2 ((compound_literal), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3023, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_4))
= true;
3024 if (fcl_context == fcl_c99)
3025 CONSTRUCTOR_C99_COMPOUND_LITERAL (compound_literal)(((tree_not_check2 (((tree_check ((compound_literal), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3025, __FUNCTION__, (CONSTRUCTOR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3025, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_3))
= 1;
3026 }
3027
3028 /* Put static/constant array temporaries in static variables. */
3029 /* FIXME all C99 compound literals should be variables rather than C++
3030 temporaries, unless they are used as an aggregate initializer. */
3031 if ((!at_function_scope_p () || CP_TYPE_CONST_P (type)((cp_type_quals (type) & TYPE_QUAL_CONST) != 0))
3032 && fcl_context == fcl_c99
3033 && TREE_CODE (type)((enum tree_code) (type)->base.code) == ARRAY_TYPE
3034 && !TYPE_HAS_NONTRIVIAL_DESTRUCTOR (type)(((tree_class_check ((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3034, __FUNCTION__))->type_common.lang_flag_4))
3035 && initializer_constant_valid_p (compound_literal, type))
3036 {
3037 tree decl = create_temporary_var (type);
3038 DECL_CONTEXT (decl)((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3038, __FUNCTION__))->decl_minimal.context)
= NULL_TREE(tree) __null;
3039 DECL_INITIAL (decl)((contains_struct_check ((decl), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3039, __FUNCTION__))->decl_common.initial)
= compound_literal;
3040 TREE_STATIC (decl)((decl)->base.static_flag) = 1;
3041 if (literal_type_p (type) && CP_TYPE_CONST_NON_VOLATILE_P (type)((cp_type_quals (type) & (TYPE_QUAL_CONST | TYPE_QUAL_VOLATILE
)) == TYPE_QUAL_CONST)
)
3042 {
3043 /* 5.19 says that a constant expression can include an
3044 lvalue-rvalue conversion applied to "a glvalue of literal type
3045 that refers to a non-volatile temporary object initialized
3046 with a constant expression". Rather than try to communicate
3047 that this VAR_DECL is a temporary, just mark it constexpr. */
3048 DECL_DECLARED_CONSTEXPR_P (decl)((contains_struct_check (((tree_check2 (((((enum tree_code) (
decl)->base.code) == TEMPLATE_DECL ? ((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((decl
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3048, __FUNCTION__, (TEMPLATE_DECL))))))))->result : decl
)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3048, __FUNCTION__, (VAR_DECL), (FUNCTION_DECL)))), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3048, __FUNCTION__))->decl_common.lang_flag_8)
= true;
3049 DECL_INITIALIZED_BY_CONSTANT_EXPRESSION_P (decl)(((tree_not_check2 (((tree_check ((decl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3049, __FUNCTION__, (VAR_DECL)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3049, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_2))
= true;
3050 TREE_CONSTANT (decl)((non_type_check ((decl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3050, __FUNCTION__))->base.constant_flag)
= true;
3051 }
3052 cp_apply_type_quals_to_decl (cp_type_quals (type), decl);
3053 decl = pushdecl_top_level (decl);
3054 DECL_NAME (decl)((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3054, __FUNCTION__))->decl_minimal.name)
= make_anon_name ();
3055 SET_DECL_ASSEMBLER_NAME (decl, DECL_NAME (decl))overwrite_decl_assembler_name (decl, ((contains_struct_check (
(decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3055, __FUNCTION__))->decl_minimal.name))
;
3056 /* Make sure the destructor is callable. */
3057 tree clean = cxx_maybe_build_cleanup (decl, complain);
3058 if (clean == error_mark_nodeglobal_trees[TI_ERROR_MARK])
3059 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3060 return decl;
3061 }
3062
3063 /* Represent other compound literals with TARGET_EXPR so we produce
3064 an lvalue, but can elide copies. */
3065 if (!VECTOR_TYPE_P (type)(((enum tree_code) (type)->base.code) == VECTOR_TYPE))
3066 compound_literal = get_target_expr_sfinae (compound_literal, complain);
3067
3068 return compound_literal;
3069}
3070
3071/* Return the declaration for the function-name variable indicated by
3072 ID. */
3073
3074tree
3075finish_fname (tree id)
3076{
3077 tree decl;
3078
3079 decl = fname_decl (input_location, C_RID_CODE (id)((enum rid) (((struct c_common_identifier *) (id))->node.rid_code
))
, id);
3080 if (processing_template_declscope_chain->x_processing_template_decl && current_function_decl
3081 && decl != error_mark_nodeglobal_trees[TI_ERROR_MARK])
3082 decl = DECL_NAME (decl)((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3082, __FUNCTION__))->decl_minimal.name)
;
3083 return decl;
3084}
3085
3086/* Finish a translation unit. */
3087
3088void
3089finish_translation_unit (void)
3090{
3091 /* In case there were missing closebraces,
3092 get us back to the global binding level. */
3093 pop_everything ();
3094 while (current_namespacescope_chain->old_namespace != global_namespacecp_global_trees[CPTI_GLOBAL])
3095 pop_namespace ();
3096
3097 /* Do file scope __FUNCTION__ et al. */
3098 finish_fname_decls ();
3099
3100 if (scope_chain->omp_declare_target_attribute)
3101 {
3102 if (!errorcount(global_dc)->diagnostic_count[(int) (DK_ERROR)])
3103 error ("%<#pragma omp declare target%> without corresponding "
3104 "%<#pragma omp end declare target%>");
3105 scope_chain->omp_declare_target_attribute = 0;
3106 }
3107}
3108
3109/* Finish a template type parameter, specified as AGGR IDENTIFIER.
3110 Returns the parameter. */
3111
3112tree
3113finish_template_type_parm (tree aggr, tree identifier)
3114{
3115 if (aggr != class_type_nodecp_global_trees[CPTI_CLASS_TYPE])
3116 {
3117 permerror (input_location, "template type parameters must use the keyword %<class%> or %<typename%>");
3118 aggr = class_type_nodecp_global_trees[CPTI_CLASS_TYPE];
3119 }
3120
3121 return build_tree_list (aggr, identifier);
3122}
3123
3124/* Finish a template template parameter, specified as AGGR IDENTIFIER.
3125 Returns the parameter. */
3126
3127tree
3128finish_template_template_parm (tree aggr, tree identifier)
3129{
3130 tree decl = build_decl (input_location,
3131 TYPE_DECL, identifier, NULL_TREE(tree) __null);
3132
3133 tree tmpl = build_lang_decl (TEMPLATE_DECL, identifier, NULL_TREE(tree) __null);
3134 DECL_TEMPLATE_PARMS (tmpl)((struct tree_template_decl *)(const_cast<union tree_node *
> ((((tree_check ((tmpl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3134, __FUNCTION__, (TEMPLATE_DECL))))))))->arguments
= current_template_parmsscope_chain->template_parms;
3135 DECL_TEMPLATE_RESULT (tmpl)((struct tree_template_decl *)(const_cast<union tree_node *
> ((((tree_check ((tmpl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3135, __FUNCTION__, (TEMPLATE_DECL))))))))->result
= decl;
3136 DECL_ARTIFICIAL (decl)((contains_struct_check ((decl), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3136, __FUNCTION__))->decl_common.artificial_flag)
= 1;
3137
3138 /* Associate the constraints with the underlying declaration,
3139 not the template. */
3140 tree reqs = TEMPLATE_PARMS_CONSTRAINTS (current_template_parms)((contains_struct_check (((tree_check ((scope_chain->template_parms
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3140, __FUNCTION__, (TREE_LIST)))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3140, __FUNCTION__))->typed.type)
;
3141 tree constr = build_constraints (reqs, NULL_TREE(tree) __null);
3142 set_constraints (decl, constr);
3143
3144 end_template_decl ();
3145
3146 gcc_assert (DECL_TEMPLATE_PARMS (tmpl))((void)(!(((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((tmpl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3146, __FUNCTION__, (TEMPLATE_DECL))))))))->arguments) ?
fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3146, __FUNCTION__), 0 : 0))
;
3147
3148 check_default_tmpl_args (decl, DECL_TEMPLATE_PARMS (tmpl)((struct tree_template_decl *)(const_cast<union tree_node *
> ((((tree_check ((tmpl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3148, __FUNCTION__, (TEMPLATE_DECL))))))))->arguments
,
3149 /*is_primary=*/true, /*is_partial=*/false,
3150 /*is_friend=*/0);
3151
3152 return finish_template_type_parm (aggr, tmpl);
3153}
3154
3155/* ARGUMENT is the default-argument value for a template template
3156 parameter. If ARGUMENT is invalid, issue error messages and return
3157 the ERROR_MARK_NODE. Otherwise, ARGUMENT itself is returned. */
3158
3159tree
3160check_template_template_default_arg (tree argument)
3161{
3162 if (TREE_CODE (argument)((enum tree_code) (argument)->base.code) != TEMPLATE_DECL
3163 && TREE_CODE (argument)((enum tree_code) (argument)->base.code) != TEMPLATE_TEMPLATE_PARM
3164 && TREE_CODE (argument)((enum tree_code) (argument)->base.code) != UNBOUND_CLASS_TEMPLATE)
3165 {
3166 if (TREE_CODE (argument)((enum tree_code) (argument)->base.code) == TYPE_DECL)
3167 error ("invalid use of type %qT as a default value for a template "
3168 "template-parameter", TREE_TYPE (argument)((contains_struct_check ((argument), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3168, __FUNCTION__))->typed.type)
);
3169 else
3170 error ("invalid default argument for a template template parameter");
3171 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3172 }
3173
3174 return argument;
3175}
3176
3177/* Begin a class definition, as indicated by T. */
3178
3179tree
3180begin_class_definition (tree t)
3181{
3182 if (error_operand_p (t)((t) == global_trees[TI_ERROR_MARK] || ((t) && ((contains_struct_check
(((t)), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3182, __FUNCTION__))->typed.type) == global_trees[TI_ERROR_MARK
]))
|| error_operand_p (TYPE_MAIN_DECL (t))((((((contains_struct_check (((tree_class_check ((((tree_class_check
((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3182, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3182, __FUNCTION__))), (TS_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3182, __FUNCTION__))->common.chain)))) == global_trees[TI_ERROR_MARK
] || ((((((contains_struct_check (((tree_class_check ((((tree_class_check
((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3182, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3182, __FUNCTION__))), (TS_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3182, __FUNCTION__))->common.chain)))) && ((contains_struct_check
(((((((contains_struct_check (((tree_class_check ((((tree_class_check
((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3182, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3182, __FUNCTION__))), (TS_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3182, __FUNCTION__))->common.chain))))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3182, __FUNCTION__))->typed.type) == global_trees[TI_ERROR_MARK
]))
)
3183 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3184
3185 if (processing_template_parmlist && !LAMBDA_TYPE_P (t)(((enum tree_code) (t)->base.code) == RECORD_TYPE &&
((((tree_class_check ((((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__))->type_common.name))) && ((tree_check
((((((tree_class_check ((((tree_class_check ((t), (tcc_type)
, "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__))->type_common.name)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3185, __FUNCTION__, (IDENTIFIER_NODE)))->base.protected_flag
))
)
3186 {
3187 error ("definition of %q#T inside template parameter list", t);
3188 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3189 }
3190
3191 /* According to the C++ ABI, decimal classes defined in ISO/IEC TR 24733
3192 are passed the same as decimal scalar types. */
3193 if (TREE_CODE (t)((enum tree_code) (t)->base.code) == RECORD_TYPE
3194 && !processing_template_declscope_chain->x_processing_template_decl)
3195 {
3196 tree ns = TYPE_CONTEXT (t)((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3196, __FUNCTION__))->type_common.context)
;
3197 if (ns && TREE_CODE (ns)((enum tree_code) (ns)->base.code) == NAMESPACE_DECL
3198 && DECL_CONTEXT (ns)((contains_struct_check ((ns), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3198, __FUNCTION__))->decl_minimal.context)
== std_nodecp_global_trees[CPTI_STD]
3199 && DECL_NAME (ns)((contains_struct_check ((ns), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3199, __FUNCTION__))->decl_minimal.name)
3200 && id_equal (DECL_NAME (ns)((contains_struct_check ((ns), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3200, __FUNCTION__))->decl_minimal.name)
, "decimal"))
3201 {
3202 const char *n = TYPE_NAME_STRING (t)(((const char *) (tree_check (((((tree_class_check ((t), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3202, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((t), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3202, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3202, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3202, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3202, __FUNCTION__))->type_common.name))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3202, __FUNCTION__, (IDENTIFIER_NODE)))->identifier.id.str
))
;
3203 if ((strcmp (n, "decimal32") == 0)
3204 || (strcmp (n, "decimal64") == 0)
3205 || (strcmp (n, "decimal128") == 0))
3206 TYPE_TRANSPARENT_AGGR (t)((tree_check3 ((t), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3206, __FUNCTION__, (RECORD_TYPE), (UNION_TYPE), (QUAL_UNION_TYPE
)))->type_common.transparent_aggr_flag)
= 1;
3207 }
3208 }
3209
3210 /* A non-implicit typename comes from code like:
3211
3212 template <typename T> struct A {
3213 template <typename U> struct A<T>::B ...
3214
3215 This is erroneous. */
3216 else if (TREE_CODE (t)((enum tree_code) (t)->base.code) == TYPENAME_TYPE)
3217 {
3218 error ("invalid definition of qualified type %qT", t);
3219 t = error_mark_nodeglobal_trees[TI_ERROR_MARK];
3220 }
3221
3222 if (t == error_mark_nodeglobal_trees[TI_ERROR_MARK] || ! MAYBE_CLASS_TYPE_P (t)((((enum tree_code) (t)->base.code) == TEMPLATE_TYPE_PARM ||
((enum tree_code) (t)->base.code) == TYPENAME_TYPE || ((enum
tree_code) (t)->base.code) == TYPEOF_TYPE || ((enum tree_code
) (t)->base.code) == BOUND_TEMPLATE_TEMPLATE_PARM || ((enum
tree_code) (t)->base.code) == DECLTYPE_TYPE) || (((((enum
tree_code) (t)->base.code)) == RECORD_TYPE || (((enum tree_code
) (t)->base.code)) == UNION_TYPE) && ((tree_class_check
((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3222, __FUNCTION__))->type_common.lang_flag_5)))
)
3223 {
3224 t = make_class_type (RECORD_TYPE);
3225 pushtag (make_anon_name (), t);
3226 }
3227
3228 if (TYPE_BEING_DEFINED (t)((((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3228, __FUNCTION__))->type_with_lang_specific.lang_specific
))->being_defined)
)
3229 {
3230 t = make_class_type (TREE_CODE (t)((enum tree_code) (t)->base.code));
3231 pushtag (TYPE_IDENTIFIER (t)(((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3231, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((t), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3231, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3231, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3231, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3231, __FUNCTION__))->type_common.name))
, t);
3232 }
3233
3234 if (modules_p ())
3235 {
3236 if (!module_may_redeclare (TYPE_NAME (t)((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3236, __FUNCTION__))->type_common.name)
))
3237 {
3238 error ("cannot declare %qD in a different module", TYPE_NAME (t)((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3238, __FUNCTION__))->type_common.name)
);
3239 inform (DECL_SOURCE_LOCATION (TYPE_NAME (t))((contains_struct_check ((((tree_class_check ((t), (tcc_type)
, "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3239, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3239, __FUNCTION__))->decl_minimal.locus)
, "declared here");
3240 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3241 }
3242 set_instantiating_module (TYPE_NAME (t)((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3242, __FUNCTION__))->type_common.name)
);
3243 set_defining_module (TYPE_NAME (t)((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3243, __FUNCTION__))->type_common.name)
);
3244 }
3245
3246 maybe_process_partial_specialization (t);
3247 pushclass (t);
3248 TYPE_BEING_DEFINED (t)((((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3248, __FUNCTION__))->type_with_lang_specific.lang_specific
))->being_defined)
= 1;
3249 class_binding_levelscope_chain->class_bindings->defining_class_p = 1;
3250
3251 if (flag_pack_structglobal_options.x_flag_pack_struct)
3252 {
3253 tree v;
3254 TYPE_PACKED (t)((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3254, __FUNCTION__))->base.u.bits.packed_flag)
= 1;
3255 /* Even though the type is being defined for the first time
3256 here, there might have been a forward declaration, so there
3257 might be cv-qualified variants of T. */
3258 for (v = TYPE_NEXT_VARIANT (t)((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3258, __FUNCTION__))->type_common.next_variant)
; v; v = TYPE_NEXT_VARIANT (v)((tree_class_check ((v), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3258, __FUNCTION__))->type_common.next_variant)
)
3259 TYPE_PACKED (v)((tree_class_check ((v), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3259, __FUNCTION__))->base.u.bits.packed_flag)
= 1;
3260 }
3261 /* Reset the interface data, at the earliest possible
3262 moment, as it might have been set via a class foo;
3263 before. */
3264 if (! TYPE_UNNAMED_P (t)((((((tree_class_check ((((tree_class_check ((t), (tcc_type),
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.name))) && ((tree_check
((((((tree_class_check ((((tree_class_check ((t), (tcc_type)
, "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.name)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__, (IDENTIFIER_NODE)))->base.private_flag
)) && !((tree_check ((((((tree_class_check ((((tree_class_check
((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__))->type_common.name)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3264, __FUNCTION__, (IDENTIFIER_NODE)))->base.protected_flag
))
)
3265 {
3266 struct c_fileinfo *finfo = \
3267 get_fileinfo (LOCATION_FILE (input_location)((expand_location (input_location)).file));
3268 CLASSTYPE_INTERFACE_ONLY (t)((((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3268, __FUNCTION__))->type_with_lang_specific.lang_specific
))->interface_only)
= finfo->interface_only;
3269 SET_CLASSTYPE_INTERFACE_UNKNOWN_X((((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3270, __FUNCTION__))->type_with_lang_specific.lang_specific
))->interface_unknown = !!(finfo->interface_unknown))
3270 (t, finfo->interface_unknown)((((tree_class_check ((t), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3270, __FUNCTION__))->type_with_lang_specific.lang_specific
))->interface_unknown = !!(finfo->interface_unknown))
;
3271 }
3272 reset_specialization ();
3273
3274 /* Make a declaration for this class in its own scope. */
3275 build_self_reference ();
3276
3277 return t;
3278}
3279
3280/* Finish the member declaration given by DECL. */
3281
3282void
3283finish_member_declaration (tree decl)
3284{
3285 if (decl == error_mark_nodeglobal_trees[TI_ERROR_MARK] || decl == NULL_TREE(tree) __null)
3286 return;
3287
3288 if (decl == void_type_nodeglobal_trees[TI_VOID_TYPE])
3289 /* The COMPONENT was a friend, not a member, and so there's
3290 nothing for us to do. */
3291 return;
3292
3293 /* We should see only one DECL at a time. */
3294 gcc_assert (DECL_CHAIN (decl) == NULL_TREE)((void)(!((((contains_struct_check (((contains_struct_check (
(decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3294, __FUNCTION__))), (TS_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3294, __FUNCTION__))->common.chain)) == (tree) __null) ?
fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3294, __FUNCTION__), 0 : 0))
;
3295
3296 /* Don't add decls after definition. */
3297 gcc_assert (TYPE_BEING_DEFINED (current_class_type)((void)(!(((((tree_class_check ((scope_chain->class_type),
(tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3297, __FUNCTION__))->type_with_lang_specific.lang_specific
))->being_defined) || (((enum tree_code) (((contains_struct_check
((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type))->base.code) == RECORD_TYPE
&& ((((tree_class_check ((((tree_class_check ((((contains_struct_check
((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
((((contains_struct_check ((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check ((((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check ((((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name))) && ((tree_check
((((((tree_class_check ((((tree_class_check ((((contains_struct_check
((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
((((contains_struct_check ((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check ((((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check ((((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__, (IDENTIFIER_NODE)))->base.protected_flag
))) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__), 0 : 0))
3298 /* We can add lambda types when late parsing default((void)(!(((((tree_class_check ((scope_chain->class_type),
(tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3297, __FUNCTION__))->type_with_lang_specific.lang_specific
))->being_defined) || (((enum tree_code) (((contains_struct_check
((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type))->base.code) == RECORD_TYPE
&& ((((tree_class_check ((((tree_class_check ((((contains_struct_check
((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
((((contains_struct_check ((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check ((((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check ((((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name))) && ((tree_check
((((((tree_class_check ((((tree_class_check ((((contains_struct_check
((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
((((contains_struct_check ((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check ((((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check ((((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__, (IDENTIFIER_NODE)))->base.protected_flag
))) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__), 0 : 0))
3299 arguments. */((void)(!(((((tree_class_check ((scope_chain->class_type),
(tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3297, __FUNCTION__))->type_with_lang_specific.lang_specific
))->being_defined) || (((enum tree_code) (((contains_struct_check
((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type))->base.code) == RECORD_TYPE
&& ((((tree_class_check ((((tree_class_check ((((contains_struct_check
((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
((((contains_struct_check ((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check ((((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check ((((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name))) && ((tree_check
((((((tree_class_check ((((tree_class_check ((((contains_struct_check
((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
((((contains_struct_check ((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check ((((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check ((((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__, (IDENTIFIER_NODE)))->base.protected_flag
))) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__), 0 : 0))
3300 || LAMBDA_TYPE_P (TREE_TYPE (decl)))((void)(!(((((tree_class_check ((scope_chain->class_type),
(tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3297, __FUNCTION__))->type_with_lang_specific.lang_specific
))->being_defined) || (((enum tree_code) (((contains_struct_check
((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type))->base.code) == RECORD_TYPE
&& ((((tree_class_check ((((tree_class_check ((((contains_struct_check
((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
((((contains_struct_check ((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check ((((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check ((((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name))) && ((tree_check
((((((tree_class_check ((((tree_class_check ((((contains_struct_check
((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
((((contains_struct_check ((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check ((((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check ((((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__))->type_common.name)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__, (IDENTIFIER_NODE)))->base.protected_flag
))) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3300, __FUNCTION__), 0 : 0))
;
3301
3302 /* Set up access control for DECL. */
3303 TREE_PRIVATE (decl)((decl)->base.private_flag)
3304 = (current_access_specifierscope_chain->access_specifier == access_private_nodeglobal_trees[TI_PRIVATE]);
3305 TREE_PROTECTED (decl)((decl)->base.protected_flag)
3306 = (current_access_specifierscope_chain->access_specifier == access_protected_nodeglobal_trees[TI_PROTECTED]);
3307 if (TREE_CODE (decl)((enum tree_code) (decl)->base.code) == TEMPLATE_DECL)
3308 {
3309 TREE_PRIVATE (DECL_TEMPLATE_RESULT (decl))((((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((decl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3309, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.private_flag)
= TREE_PRIVATE (decl)((decl)->base.private_flag);
3310 TREE_PROTECTED (DECL_TEMPLATE_RESULT (decl))((((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((decl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3310, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.protected_flag)
= TREE_PROTECTED (decl)((decl)->base.protected_flag);
3311 }
3312
3313 /* Mark the DECL as a member of the current class, unless it's
3314 a member of an enumeration. */
3315 if (TREE_CODE (decl)((enum tree_code) (decl)->base.code) != CONST_DECL)
3316 DECL_CONTEXT (decl)((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3316, __FUNCTION__))->decl_minimal.context)
= current_class_typescope_chain->class_type;
3317
3318 if (TREE_CODE (decl)((enum tree_code) (decl)->base.code) == USING_DECL)
3319 /* For now, ignore class-scope USING_DECLS, so that debugging
3320 backends do not see them. */
3321 DECL_IGNORED_P (decl)((contains_struct_check ((decl), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3321, __FUNCTION__))->decl_common.ignored_flag)
= 1;
3322
3323 /* Check for bare parameter packs in the non-static data member
3324 declaration. */
3325 if (TREE_CODE (decl)((enum tree_code) (decl)->base.code) == FIELD_DECL)
3326 {
3327 if (check_for_bare_parameter_packs (TREE_TYPE (decl)((contains_struct_check ((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3327, __FUNCTION__))->typed.type)
))
3328 TREE_TYPE (decl)((contains_struct_check ((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3328, __FUNCTION__))->typed.type)
= error_mark_nodeglobal_trees[TI_ERROR_MARK];
3329 if (check_for_bare_parameter_packs (DECL_ATTRIBUTES (decl)((contains_struct_check ((decl), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3329, __FUNCTION__))->decl_common.attributes)
))
3330 DECL_ATTRIBUTES (decl)((contains_struct_check ((decl), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3330, __FUNCTION__))->decl_common.attributes)
= NULL_TREE(tree) __null;
3331 }
3332
3333 /* [dcl.link]
3334
3335 A C language linkage is ignored for the names of class members
3336 and the member function type of class member functions. */
3337 if (DECL_LANG_SPECIFIC (decl)((contains_struct_check ((decl), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3337, __FUNCTION__))->decl_common.lang_specific)
)
3338 SET_DECL_LANGUAGE (decl, lang_cplusplus)(((contains_struct_check ((decl), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3338, __FUNCTION__))->decl_common.lang_specific)->u.base
.language = (lang_cplusplus))
;
3339
3340 bool add = false;
3341
3342 /* Functions and non-functions are added differently. */
3343 if (DECL_DECLARES_FUNCTION_P (decl)(((enum tree_code) (decl)->base.code) == FUNCTION_DECL || (
((enum tree_code) (decl)->base.code) == TEMPLATE_DECL &&
((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((decl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3343, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((decl
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3343, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL))
)
3344 add = add_method (current_class_typescope_chain->class_type, decl, false);
3345 /* Enter the DECL into the scope of the class, if the class
3346 isn't a closure (whose fields are supposed to be unnamed). */
3347 else if (CLASSTYPE_LAMBDA_EXPR (current_class_type)((((tree_class_check ((scope_chain->class_type), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3347, __FUNCTION__))->type_with_lang_specific.lang_specific
))->lambda_expr)
3348 || pushdecl_class_level (decl))
3349 add = true;
3350
3351 if (add)
3352 {
3353 /* All TYPE_DECLs go at the end of TYPE_FIELDS. Ordinary fields
3354 go at the beginning. The reason is that
3355 legacy_nonfn_member_lookup searches the list in order, and we
3356 want a field name to override a type name so that the "struct
3357 stat hack" will work. In particular:
3358
3359 struct S { enum E { }; static const int E = 5; int ary[S::E]; } s;
3360
3361 is valid. */
3362
3363 if (TREE_CODE (decl)((enum tree_code) (decl)->base.code) == TYPE_DECL)
3364 TYPE_FIELDS (current_class_type)((tree_check3 ((scope_chain->class_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3364, __FUNCTION__, (RECORD_TYPE), (UNION_TYPE), (QUAL_UNION_TYPE
)))->type_non_common.values)
3365 = chainon (TYPE_FIELDS (current_class_type)((tree_check3 ((scope_chain->class_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3365, __FUNCTION__, (RECORD_TYPE), (UNION_TYPE), (QUAL_UNION_TYPE
)))->type_non_common.values)
, decl);
3366 else
3367 {
3368 DECL_CHAIN (decl)(((contains_struct_check (((contains_struct_check ((decl), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3368, __FUNCTION__))), (TS_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3368, __FUNCTION__))->common.chain))
= TYPE_FIELDS (current_class_type)((tree_check3 ((scope_chain->class_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3368, __FUNCTION__, (RECORD_TYPE), (UNION_TYPE), (QUAL_UNION_TYPE
)))->type_non_common.values)
;
3369 TYPE_FIELDS (current_class_type)((tree_check3 ((scope_chain->class_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3369, __FUNCTION__, (RECORD_TYPE), (UNION_TYPE), (QUAL_UNION_TYPE
)))->type_non_common.values)
= decl;
3370 }
3371
3372 maybe_add_class_template_decl_list (current_class_typescope_chain->class_type, decl,
3373 /*friend_p=*/0);
3374 }
3375}
3376
3377/* Finish processing a complete template declaration. The PARMS are
3378 the template parameters. */
3379
3380void
3381finish_template_decl (tree parms)
3382{
3383 if (parms)
3384 end_template_decl ();
3385 else
3386 end_specialization ();
3387}
3388
3389// Returns the template type of the class scope being entered. If we're
3390// entering a constrained class scope. TYPE is the class template
3391// scope being entered and we may need to match the intended type with
3392// a constrained specialization. For example:
3393//
3394// template<Object T>
3395// struct S { void f(); }; #1
3396//
3397// template<Object T>
3398// void S<T>::f() { } #2
3399//
3400// We check, in #2, that S<T> refers precisely to the type declared by
3401// #1 (i.e., that the constraints match). Note that the following should
3402// be an error since there is no specialization of S<T> that is
3403// unconstrained, but this is not diagnosed here.
3404//
3405// template<typename T>
3406// void S<T>::f() { }
3407//
3408// We cannot diagnose this problem here since this function also matches
3409// qualified template names that are not part of a definition. For example:
3410//
3411// template<Integral T, Floating_point U>
3412// typename pair<T, U>::first_type void f(T, U);
3413//
3414// Here, it is unlikely that there is a partial specialization of
3415// pair constrained for for Integral and Floating_point arguments.
3416//
3417// The general rule is: if a constrained specialization with matching
3418// constraints is found return that type. Also note that if TYPE is not a
3419// class-type (e.g. a typename type), then no fixup is needed.
3420
3421static tree
3422fixup_template_type (tree type)
3423{
3424 // Find the template parameter list at the a depth appropriate to
3425 // the scope we're trying to enter.
3426 tree parms = current_template_parmsscope_chain->template_parms;
3427 int depth = template_class_depth (type);
3428 for (int n = processing_template_declscope_chain->x_processing_template_decl; n > depth && parms; --n)
3429 parms = TREE_CHAIN (parms)((contains_struct_check ((parms), (TS_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3429, __FUNCTION__))->common.chain)
;
3430 if (!parms)
3431 return type;
3432 tree cur_reqs = TEMPLATE_PARMS_CONSTRAINTS (parms)((contains_struct_check (((tree_check ((parms), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3432, __FUNCTION__, (TREE_LIST)))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3432, __FUNCTION__))->typed.type)
;
3433 tree cur_constr = build_constraints (cur_reqs, NULL_TREE(tree) __null);
3434
3435 // Search for a specialization whose type and constraints match.
3436 tree tmpl = CLASSTYPE_TI_TEMPLATE (type)((struct tree_template_info*)(tree_check (((((tree_class_check
(((tree_check3 ((type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3436, __FUNCTION__, (RECORD_TYPE), (UNION_TYPE), (QUAL_UNION_TYPE
)))), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3436, __FUNCTION__))->type_non_common.lang_1))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3436, __FUNCTION__, (TEMPLATE_INFO))))->tmpl
;
3437 tree specs = DECL_TEMPLATE_SPECIALIZATIONS (tmpl)((contains_struct_check (((tree_check ((tmpl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3437, __FUNCTION__, (TEMPLATE_DECL)))), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3437, __FUNCTION__))->decl_common.size)
;
3438 while (specs)
3439 {
3440 tree spec_constr = get_constraints (TREE_VALUE (specs)((tree_check ((specs), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3440, __FUNCTION__, (TREE_LIST)))->list.value)
);
3441
3442 // If the type and constraints match a specialization, then we
3443 // are entering that type.
3444 if (same_type_p (type, TREE_TYPE (specs))comptypes ((type), (((contains_struct_check ((specs), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3444, __FUNCTION__))->typed.type)), 0)
3445 && equivalent_constraints (cur_constr, spec_constr))
3446 return TREE_TYPE (specs)((contains_struct_check ((specs), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3446, __FUNCTION__))->typed.type)
;
3447 specs = TREE_CHAIN (specs)((contains_struct_check ((specs), (TS_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3447, __FUNCTION__))->common.chain)
;
3448 }
3449
3450 // If no specialization matches, then must return the type
3451 // previously found.
3452 return type;
3453}
3454
3455/* Finish processing a template-id (which names a type) of the form
3456 NAME < ARGS >. Return the TYPE_DECL for the type named by the
3457 template-id. If ENTERING_SCOPE is nonzero we are about to enter
3458 the scope of template-id indicated. */
3459
3460tree
3461finish_template_type (tree name, tree args, int entering_scope)
3462{
3463 tree type;
3464
3465 type = lookup_template_class (name, args,
3466 NULL_TREE(tree) __null, NULL_TREE(tree) __null, entering_scope,
3467 tf_warning_or_error | tf_user);
3468
3469 /* If we might be entering the scope of a partial specialization,
3470 find the one with the right constraints. */
3471 if (flag_conceptsglobal_options.x_flag_concepts
3472 && entering_scope
3473 && CLASS_TYPE_P (type)(((((enum tree_code) (type)->base.code)) == RECORD_TYPE ||
(((enum tree_code) (type)->base.code)) == UNION_TYPE) &&
((tree_class_check ((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3473, __FUNCTION__))->type_common.lang_flag_5))
3474 && CLASSTYPE_TEMPLATE_INFO (type)(((tree_class_check (((tree_check3 ((type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3474, __FUNCTION__, (RECORD_TYPE), (UNION_TYPE), (QUAL_UNION_TYPE
)))), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3474, __FUNCTION__))->type_non_common.lang_1))
3475 && dependent_type_p (type)
3476 && PRIMARY_TEMPLATE_P (CLASSTYPE_TI_TEMPLATE (type))(((((contains_struct_check ((((tree_check ((((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((((struct
tree_template_info*)(tree_check (((((tree_class_check (((tree_check3
((type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3476, __FUNCTION__, (RECORD_TYPE), (UNION_TYPE), (QUAL_UNION_TYPE
)))), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3476, __FUNCTION__))->type_non_common.lang_1))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3476, __FUNCTION__, (TEMPLATE_INFO))))->tmpl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3476, __FUNCTION__, (TEMPLATE_DECL))))))))->arguments), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3476, __FUNCTION__, (TREE_LIST)))->list.value)), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3476, __FUNCTION__))->typed.type))) == (((struct tree_template_info
*)(tree_check (((((tree_class_check (((tree_check3 ((type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3476, __FUNCTION__, (RECORD_TYPE), (UNION_TYPE), (QUAL_UNION_TYPE
)))), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3476, __FUNCTION__))->type_non_common.lang_1))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3476, __FUNCTION__, (TEMPLATE_INFO))))->tmpl))
)
3477 type = fixup_template_type (type);
3478
3479 if (type == error_mark_nodeglobal_trees[TI_ERROR_MARK])
3480 return type;
3481 else if (CLASS_TYPE_P (type)(((((enum tree_code) (type)->base.code)) == RECORD_TYPE ||
(((enum tree_code) (type)->base.code)) == UNION_TYPE) &&
((tree_class_check ((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3481, __FUNCTION__))->type_common.lang_flag_5))
&& !alias_type_or_template_p (type))
3482 return TYPE_STUB_DECL (type)(((contains_struct_check (((tree_class_check ((type), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3482, __FUNCTION__))), (TS_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3482, __FUNCTION__))->common.chain))
;
3483 else
3484 return TYPE_NAME (type)((tree_class_check ((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3484, __FUNCTION__))->type_common.name)
;
3485}
3486
3487/* Finish processing a BASE_CLASS with the indicated ACCESS_SPECIFIER.
3488 Return a TREE_LIST containing the ACCESS_SPECIFIER and the
3489 BASE_CLASS, or NULL_TREE if an error occurred. The
3490 ACCESS_SPECIFIER is one of
3491 access_{default,public,protected_private}_node. For a virtual base
3492 we set TREE_TYPE. */
3493
3494tree
3495finish_base_specifier (tree base, tree access, bool virtual_p)
3496{
3497 tree result;
3498
3499 if (base == error_mark_nodeglobal_trees[TI_ERROR_MARK])
3500 {
3501 error ("invalid base-class specification");
3502 result = NULL_TREE(tree) __null;
3503 }
3504 else if (! MAYBE_CLASS_TYPE_P (base)((((enum tree_code) (base)->base.code) == TEMPLATE_TYPE_PARM
|| ((enum tree_code) (base)->base.code) == TYPENAME_TYPE ||
((enum tree_code) (base)->base.code) == TYPEOF_TYPE || ((
enum tree_code) (base)->base.code) == BOUND_TEMPLATE_TEMPLATE_PARM
|| ((enum tree_code) (base)->base.code) == DECLTYPE_TYPE)
|| (((((enum tree_code) (base)->base.code)) == RECORD_TYPE
|| (((enum tree_code) (base)->base.code)) == UNION_TYPE) &&
((tree_class_check ((base), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3504, __FUNCTION__))->type_common.lang_flag_5)))
)
3505 {
3506 error ("%qT is not a class type", base);
3507 result = NULL_TREE(tree) __null;
3508 }
3509 else
3510 {
3511 if (cp_type_quals (base) != 0)
3512 {
3513 /* DR 484: Can a base-specifier name a cv-qualified
3514 class type? */
3515 base = TYPE_MAIN_VARIANT (base)((tree_class_check ((base), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3515, __FUNCTION__))->type_common.main_variant)
;
3516 }
3517 result = build_tree_list (access, base);
3518 if (virtual_p)
3519 TREE_TYPE (result)((contains_struct_check ((result), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3519, __FUNCTION__))->typed.type)
= integer_type_nodeinteger_types[itk_int];
3520 }
3521
3522 return result;
3523}
3524
3525/* If FNS is a member function, a set of member functions, or a
3526 template-id referring to one or more member functions, return a
3527 BASELINK for FNS, incorporating the current access context.
3528 Otherwise, return FNS unchanged. */
3529
3530tree
3531baselink_for_fns (tree fns)
3532{
3533 tree scope;
3534 tree cl;
3535
3536 if (BASELINK_P (fns)(((enum tree_code) (fns)->base.code) == BASELINK)
3537 || error_operand_p (fns)((fns) == global_trees[TI_ERROR_MARK] || ((fns) && ((
contains_struct_check (((fns)), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3537, __FUNCTION__))->typed.type) == global_trees[TI_ERROR_MARK
]))
)
3538 return fns;
3539
3540 scope = ovl_scope (fns);
3541 if (!CLASS_TYPE_P (scope)(((((enum tree_code) (scope)->base.code)) == RECORD_TYPE ||
(((enum tree_code) (scope)->base.code)) == UNION_TYPE) &&
((tree_class_check ((scope), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3541, __FUNCTION__))->type_common.lang_flag_5))
)
3542 return fns;
3543
3544 cl = currently_open_derived_class (scope);
3545 if (!cl)
3546 cl = scope;
3547 cl = TYPE_BINFO (cl)((tree_check3 ((cl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3547, __FUNCTION__, (RECORD_TYPE), (UNION_TYPE), (QUAL_UNION_TYPE
)))->type_non_common.maxval)
;
3548 return build_baselink (cl, cl, fns, /*optype=*/NULL_TREE(tree) __null);
3549}
3550
3551/* Returns true iff DECL is a variable from a function outside
3552 the current one. */
3553
3554static bool
3555outer_var_p (tree decl)
3556{
3557 return ((VAR_P (decl)(((enum tree_code) (decl)->base.code) == VAR_DECL) || TREE_CODE (decl)((enum tree_code) (decl)->base.code) == PARM_DECL)
3558 && DECL_FUNCTION_SCOPE_P (decl)(((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3558, __FUNCTION__))->decl_minimal.context) && (
(enum tree_code) (((contains_struct_check ((decl), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3558, __FUNCTION__))->decl_minimal.context))->base.code
) == FUNCTION_DECL)
3559 /* Don't get confused by temporaries. */
3560 && DECL_NAME (decl)((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3560, __FUNCTION__))->decl_minimal.name)
3561 && (DECL_CONTEXT (decl)((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3561, __FUNCTION__))->decl_minimal.context)
!= current_function_decl
3562 || parsing_nsdmi ()));
3563}
3564
3565/* As above, but also checks that DECL is automatic. */
3566
3567bool
3568outer_automatic_var_p (tree decl)
3569{
3570 return (outer_var_p (decl)
3571 && !TREE_STATIC (decl)((decl)->base.static_flag));
3572}
3573
3574/* DECL satisfies outer_automatic_var_p. Possibly complain about it or
3575 rewrite it for lambda capture.
3576
3577 If ODR_USE is true, we're being called from mark_use, and we complain about
3578 use of constant variables. If ODR_USE is false, we're being called for the
3579 id-expression, and we do lambda capture. */
3580
3581tree
3582process_outer_var_ref (tree decl, tsubst_flags_t complain, bool odr_use)
3583{
3584 if (cp_unevaluated_operand)
3585 {
3586 tree type = TREE_TYPE (decl)((contains_struct_check ((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3586, __FUNCTION__))->typed.type)
;
3587 if (!dependent_type_p (type)
3588 && variably_modified_type_p (type, NULL_TREE(tree) __null))
3589 /* VLAs are used even in unevaluated context. */;
3590 else
3591 /* It's not a use (3.2) if we're in an unevaluated context. */
3592 return decl;
3593 }
3594 if (decl == error_mark_nodeglobal_trees[TI_ERROR_MARK])
3595 return decl;
3596
3597 tree context = DECL_CONTEXT (decl)((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3597, __FUNCTION__))->decl_minimal.context)
;
3598 tree containing_function = current_function_decl;
3599 tree lambda_stack = NULL_TREE(tree) __null;
3600 tree lambda_expr = NULL_TREE(tree) __null;
3601 tree initializer = convert_from_reference (decl);
3602
3603 /* Mark it as used now even if the use is ill-formed. */
3604 if (!mark_used (decl, complain))
3605 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3606
3607 if (parsing_nsdmi ())
3608 containing_function = NULL_TREE(tree) __null;
3609
3610 if (containing_function && LAMBDA_FUNCTION_P (containing_function)((((enum tree_code) (containing_function)->base.code) == FUNCTION_DECL
|| (((enum tree_code) (containing_function)->base.code) ==
TEMPLATE_DECL && ((struct tree_template_decl *)(const_cast
<union tree_node *> ((((tree_check ((containing_function
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((containing_function
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)) && (((tree_not_check2 (
((tree_check ((((contains_struct_check ((containing_function)
, (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.name)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__, (IDENTIFIER_NODE)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_2)) && ((__extension__ ({ struct lang_decl
*lt = ((contains_struct_check (((((enum tree_code) (containing_function
)->base.code) == TEMPLATE_DECL ? ((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((containing_function
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__, (TEMPLATE_DECL))))))))->result : containing_function
)), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_common.lang_specific); if (!(
((enum tree_code) (containing_function)->base.code) == FUNCTION_DECL
|| (((enum tree_code) (containing_function)->base.code) ==
TEMPLATE_DECL && ((struct tree_template_decl *)(const_cast
<union tree_node *> ((((tree_check ((containing_function
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((containing_function
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)) || lt->u.base.selector != lds_fn
) lang_check_failed ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__); &lt->u.fn; })->ovl_op_code) ==
OVL_OP_CALL_EXPR) && (((enum tree_code) ((!(! (((contains_struct_check
((containing_function), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context)) || ((enum tree_code
) (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context))->base.code
) == TRANSLATION_UNIT_DECL) ? ((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context) : cp_global_trees
[CPTI_GLOBAL]))->base.code) == RECORD_TYPE && ((((
tree_class_check ((((tree_class_check (((!(! (((contains_struct_check
((containing_function), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context)) || ((enum tree_code
) (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context))->base.code
) == TRANSLATION_UNIT_DECL) ? ((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context) : cp_global_trees
[CPTI_GLOBAL])), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
(((!(! (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context)) || ((enum tree_code
) (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context))->base.code
) == TRANSLATION_UNIT_DECL) ? ((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context) : cp_global_trees
[CPTI_GLOBAL])), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check (((!(! (((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context)) || ((enum tree_code
) (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context))->base.code
) == TRANSLATION_UNIT_DECL) ? ((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context) : cp_global_trees
[CPTI_GLOBAL])), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check (((!(! (((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context)) || ((enum tree_code
) (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context))->base.code
) == TRANSLATION_UNIT_DECL) ? ((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context) : cp_global_trees
[CPTI_GLOBAL])), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->type_common.name))) && ((tree_check
((((((tree_class_check ((((tree_class_check (((!(! (((contains_struct_check
((containing_function), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context)) || ((enum tree_code
) (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context))->base.code
) == TRANSLATION_UNIT_DECL) ? ((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context) : cp_global_trees
[CPTI_GLOBAL])), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
(((!(! (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context)) || ((enum tree_code
) (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context))->base.code
) == TRANSLATION_UNIT_DECL) ? ((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context) : cp_global_trees
[CPTI_GLOBAL])), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check (((!(! (((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context)) || ((enum tree_code
) (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context))->base.code
) == TRANSLATION_UNIT_DECL) ? ((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context) : cp_global_trees
[CPTI_GLOBAL])), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check (((!(! (((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context)) || ((enum tree_code
) (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context))->base.code
) == TRANSLATION_UNIT_DECL) ? ((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->decl_minimal.context) : cp_global_trees
[CPTI_GLOBAL])), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__))->type_common.name)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3610, __FUNCTION__, (IDENTIFIER_NODE)))->base.protected_flag
)))
)
3611 {
3612 /* Check whether we've already built a proxy. */
3613 tree var = decl;
3614 while (is_normal_capture_proxy (var))
3615 var = DECL_CAPTURED_VARIABLE (var)(__extension__ ({ struct lang_decl *lt = ((contains_struct_check
((var), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3615, __FUNCTION__))->decl_common.lang_specific); if (!(
(((enum tree_code) (var)->base.code) == VAR_DECL || ((enum
tree_code) (var)->base.code) == FUNCTION_DECL) || ((enum tree_code
) (var)->base.code) == FIELD_DECL || ((enum tree_code) (var
)->base.code) == CONST_DECL || ((enum tree_code) (var)->
base.code) == TYPE_DECL || ((enum tree_code) (var)->base.code
) == TEMPLATE_DECL || ((enum tree_code) (var)->base.code) ==
USING_DECL || ((enum tree_code) (var)->base.code) == CONCEPT_DECL
)) lang_check_failed ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3615, __FUNCTION__); &lt->u.min; })->access)
;
3616 tree d = retrieve_local_specialization (var);
3617
3618 if (d && d != decl && is_capture_proxy (d))
3619 {
3620 if (DECL_CONTEXT (d)((contains_struct_check ((d), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3620, __FUNCTION__))->decl_minimal.context)
== containing_function)
3621 /* We already have an inner proxy. */
3622 return d;
3623 else
3624 /* We need to capture an outer proxy. */
3625 return process_outer_var_ref (d, complain, odr_use);
3626 }
3627 }
3628
3629 /* If we are in a lambda function, we can move out until we hit
3630 1. the context,
3631 2. a non-lambda function, or
3632 3. a non-default capturing lambda function. */
3633 while (context != containing_function
3634 /* containing_function can be null with invalid generic lambdas. */
3635 && containing_function
3636 && LAMBDA_FUNCTION_P (containing_function)((((enum tree_code) (containing_function)->base.code) == FUNCTION_DECL
|| (((enum tree_code) (containing_function)->base.code) ==
TEMPLATE_DECL && ((struct tree_template_decl *)(const_cast
<union tree_node *> ((((tree_check ((containing_function
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((containing_function
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)) && (((tree_not_check2 (
((tree_check ((((contains_struct_check ((containing_function)
, (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.name)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__, (IDENTIFIER_NODE)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_2)) && ((__extension__ ({ struct lang_decl
*lt = ((contains_struct_check (((((enum tree_code) (containing_function
)->base.code) == TEMPLATE_DECL ? ((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((containing_function
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__, (TEMPLATE_DECL))))))))->result : containing_function
)), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_common.lang_specific); if (!(
((enum tree_code) (containing_function)->base.code) == FUNCTION_DECL
|| (((enum tree_code) (containing_function)->base.code) ==
TEMPLATE_DECL && ((struct tree_template_decl *)(const_cast
<union tree_node *> ((((tree_check ((containing_function
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((containing_function
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)) || lt->u.base.selector != lds_fn
) lang_check_failed ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__); &lt->u.fn; })->ovl_op_code) ==
OVL_OP_CALL_EXPR) && (((enum tree_code) ((!(! (((contains_struct_check
((containing_function), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context)) || ((enum tree_code
) (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context))->base.code
) == TRANSLATION_UNIT_DECL) ? ((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context) : cp_global_trees
[CPTI_GLOBAL]))->base.code) == RECORD_TYPE && ((((
tree_class_check ((((tree_class_check (((!(! (((contains_struct_check
((containing_function), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context)) || ((enum tree_code
) (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context))->base.code
) == TRANSLATION_UNIT_DECL) ? ((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context) : cp_global_trees
[CPTI_GLOBAL])), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
(((!(! (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context)) || ((enum tree_code
) (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context))->base.code
) == TRANSLATION_UNIT_DECL) ? ((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context) : cp_global_trees
[CPTI_GLOBAL])), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check (((!(! (((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context)) || ((enum tree_code
) (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context))->base.code
) == TRANSLATION_UNIT_DECL) ? ((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context) : cp_global_trees
[CPTI_GLOBAL])), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check (((!(! (((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context)) || ((enum tree_code
) (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context))->base.code
) == TRANSLATION_UNIT_DECL) ? ((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context) : cp_global_trees
[CPTI_GLOBAL])), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->type_common.name))) && ((tree_check
((((((tree_class_check ((((tree_class_check (((!(! (((contains_struct_check
((containing_function), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context)) || ((enum tree_code
) (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context))->base.code
) == TRANSLATION_UNIT_DECL) ? ((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context) : cp_global_trees
[CPTI_GLOBAL])), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->type_common.name) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((((tree_class_check
(((!(! (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context)) || ((enum tree_code
) (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context))->base.code
) == TRANSLATION_UNIT_DECL) ? ((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context) : cp_global_trees
[CPTI_GLOBAL])), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->type_common.name))->base.code))
] == tcc_declaration) ? ((contains_struct_check ((((tree_class_check
((((tree_class_check (((!(! (((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context)) || ((enum tree_code
) (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context))->base.code
) == TRANSLATION_UNIT_DECL) ? ((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context) : cp_global_trees
[CPTI_GLOBAL])), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->type_common.name)), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.name) : ((tree_class_check
((((tree_class_check (((!(! (((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context)) || ((enum tree_code
) (((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context))->base.code
) == TRANSLATION_UNIT_DECL) ? ((contains_struct_check ((containing_function
), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->decl_minimal.context) : cp_global_trees
[CPTI_GLOBAL])), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->type_common.main_variant)), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__))->type_common.name)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3636, __FUNCTION__, (IDENTIFIER_NODE)))->base.protected_flag
)))
)
3637 {
3638 tree closure = DECL_CONTEXT (containing_function)((contains_struct_check ((containing_function), (TS_DECL_MINIMAL
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3638, __FUNCTION__))->decl_minimal.context)
;
3639 lambda_expr = CLASSTYPE_LAMBDA_EXPR (closure)((((tree_class_check ((closure), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3639, __FUNCTION__))->type_with_lang_specific.lang_specific
))->lambda_expr)
;
3640
3641 if (TYPE_CLASS_SCOPE_P (closure)(((tree_class_check ((closure), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3641, __FUNCTION__))->type_common.context) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((closure), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3641, __FUNCTION__))->type_common.context))->base.code
))] == tcc_type))
)
3642 /* A lambda in an NSDMI (c++/64496). */
3643 break;
3644
3645 if (LAMBDA_EXPR_DEFAULT_CAPTURE_MODE (lambda_expr)(((struct tree_lambda_expr *)(tree_check ((lambda_expr), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3645, __FUNCTION__, (LAMBDA_EXPR))))->default_capture_mode
)
== CPLD_NONE)
3646 break;
3647
3648 lambda_stack = tree_cons (NULL_TREE(tree) __null, lambda_expr, lambda_stack);
3649
3650 containing_function = decl_function_context (containing_function);
3651 }
3652
3653 /* In a lambda within a template, wait until instantiation time to implicitly
3654 capture a parameter pack. We want to wait because we don't know if we're
3655 capturing the whole pack or a single element, and it's OK to wait because
3656 find_parameter_packs_r walks into the lambda body. */
3657 if (context == containing_function
3658 && DECL_PACK_P (decl)((tree_code_type[(int) (((enum tree_code) (decl)->base.code
))] == tcc_declaration) && (((enum tree_code) (((contains_struct_check
((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3658, __FUNCTION__))->typed.type))->base.code) == TYPE_PACK_EXPANSION
|| ((enum tree_code) (((contains_struct_check ((decl), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3658, __FUNCTION__))->typed.type))->base.code) == EXPR_PACK_EXPANSION
))
)
3659 return decl;
3660
3661 if (lambda_expr && VAR_P (decl)(((enum tree_code) (decl)->base.code) == VAR_DECL) && DECL_ANON_UNION_VAR_P (decl)(((contains_struct_check (((tree_check ((decl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3661, __FUNCTION__, (VAR_DECL)))), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3661, __FUNCTION__))->decl_common.lang_flag_4))
)
3662 {
3663 if (complain & tf_error)
3664 error ("cannot capture member %qD of anonymous union", decl);
3665 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3666 }
3667 /* Do lambda capture when processing the id-expression, not when
3668 odr-using a variable. */
3669 if (!odr_use && context == containing_function)
3670 decl = add_default_capture (lambda_stack,
3671 /*id=*/DECL_NAME (decl)((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3671, __FUNCTION__))->decl_minimal.name)
, initializer);
3672 /* Only an odr-use of an outer automatic variable causes an
3673 error, and a constant variable can decay to a prvalue
3674 constant without odr-use. So don't complain yet. */
3675 else if (!odr_use && decl_constant_var_p (decl))
3676 return decl;
3677 else if (lambda_expr)
3678 {
3679 if (complain & tf_error)
3680 {
3681 error ("%qD is not captured", decl);
3682 tree closure = LAMBDA_EXPR_CLOSURE (lambda_expr)(((contains_struct_check (((tree_check ((lambda_expr), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3682, __FUNCTION__, (LAMBDA_EXPR)))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3682, __FUNCTION__))->typed.type))
;
3683 if (LAMBDA_EXPR_DEFAULT_CAPTURE_MODE (lambda_expr)(((struct tree_lambda_expr *)(tree_check ((lambda_expr), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3683, __FUNCTION__, (LAMBDA_EXPR))))->default_capture_mode
)
== CPLD_NONE)
3684 inform (location_of (closure),
3685 "the lambda has no capture-default");
3686 else if (TYPE_CLASS_SCOPE_P (closure)(((tree_class_check ((closure), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3686, __FUNCTION__))->type_common.context) && (tree_code_type
[(int) (((enum tree_code) (((tree_class_check ((closure), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3686, __FUNCTION__))->type_common.context))->base.code
))] == tcc_type))
)
3687 inform (UNKNOWN_LOCATION((location_t) 0), "lambda in local class %q+T cannot "
3688 "capture variables from the enclosing context",
3689 TYPE_CONTEXT (closure)((tree_class_check ((closure), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3689, __FUNCTION__))->type_common.context)
);
3690 inform (DECL_SOURCE_LOCATION (decl)((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3690, __FUNCTION__))->decl_minimal.locus)
, "%q#D declared here", decl);
3691 }
3692 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3693 }
3694 else
3695 {
3696 if (complain & tf_error)
3697 {
3698 error (VAR_P (decl)(((enum tree_code) (decl)->base.code) == VAR_DECL)
3699 ? G_("use of local variable with automatic storage from ""use of local variable with automatic storage from " "containing function"
3700 "containing function")"use of local variable with automatic storage from " "containing function"
3701 : G_("use of parameter from containing function")"use of parameter from containing function");
3702 inform (DECL_SOURCE_LOCATION (decl)((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3702, __FUNCTION__))->decl_minimal.locus)
, "%q#D declared here", decl);
3703 }
3704 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3705 }
3706 return decl;
3707}
3708
3709/* ID_EXPRESSION is a representation of parsed, but unprocessed,
3710 id-expression. (See cp_parser_id_expression for details.) SCOPE,
3711 if non-NULL, is the type or namespace used to explicitly qualify
3712 ID_EXPRESSION. DECL is the entity to which that name has been
3713 resolved.
3714
3715 *CONSTANT_EXPRESSION_P is true if we are presently parsing a
3716 constant-expression. In that case, *NON_CONSTANT_EXPRESSION_P will
3717 be set to true if this expression isn't permitted in a
3718 constant-expression, but it is otherwise not set by this function.
3719 *ALLOW_NON_CONSTANT_EXPRESSION_P is true if we are parsing a
3720 constant-expression, but a non-constant expression is also
3721 permissible.
3722
3723 DONE is true if this expression is a complete postfix-expression;
3724 it is false if this expression is followed by '->', '[', '(', etc.
3725 ADDRESS_P is true iff this expression is the operand of '&'.
3726 TEMPLATE_P is true iff the qualified-id was of the form
3727 "A::template B". TEMPLATE_ARG_P is true iff this qualified name
3728 appears as a template argument.
3729
3730 If an error occurs, and it is the kind of error that might cause
3731 the parser to abort a tentative parse, *ERROR_MSG is filled in. It
3732 is the caller's responsibility to issue the message. *ERROR_MSG
3733 will be a string with static storage duration, so the caller need
3734 not "free" it.
3735
3736 Return an expression for the entity, after issuing appropriate
3737 diagnostics. This function is also responsible for transforming a
3738 reference to a non-static member into a COMPONENT_REF that makes
3739 the use of "this" explicit.
3740
3741 Upon return, *IDK will be filled in appropriately. */
3742static cp_expr
3743finish_id_expression_1 (tree id_expression,
3744 tree decl,
3745 tree scope,
3746 cp_id_kind *idk,
3747 bool integral_constant_expression_p,
3748 bool allow_non_integral_constant_expression_p,
3749 bool *non_integral_constant_expression_p,
3750 bool template_p,
3751 bool done,
3752 bool address_p,
3753 bool template_arg_p,
3754 const char **error_msg,
3755 location_t location)
3756{
3757 decl = strip_using_decl (decl);
3758
3759 /* Initialize the output parameters. */
3760 *idk = CP_ID_KIND_NONE;
3761 *error_msg = NULL__null;
3762
3763 if (id_expression == error_mark_nodeglobal_trees[TI_ERROR_MARK])
3764 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3765 /* If we have a template-id, then no further lookup is
3766 required. If the template-id was for a template-class, we
3767 will sometimes have a TYPE_DECL at this point. */
3768 else if (TREE_CODE (decl)((enum tree_code) (decl)->base.code) == TEMPLATE_ID_EXPR
3769 || TREE_CODE (decl)((enum tree_code) (decl)->base.code) == TYPE_DECL)
3770 ;
3771 /* Look up the name. */
3772 else
3773 {
3774 if (decl == error_mark_nodeglobal_trees[TI_ERROR_MARK])
3775 {
3776 /* Name lookup failed. */
3777 if (scope
3778 && (!TYPE_P (scope)(tree_code_type[(int) (((enum tree_code) (scope)->base.code
))] == tcc_type)
3779 || (!dependent_type_p (scope)
3780 && !(identifier_p (id_expression)
3781 && IDENTIFIER_CONV_OP_P (id_expression)((((tree_not_check2 (((tree_check ((id_expression), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3781, __FUNCTION__, (IDENTIFIER_NODE)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3781, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_2)) & ((tree_not_check2 (((tree_check ((id_expression
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3781, __FUNCTION__, (IDENTIFIER_NODE)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3781, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_1) & (!((tree_not_check2 (((tree_check ((id_expression
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3781, __FUNCTION__, (IDENTIFIER_NODE)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3781, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_0)))
3782 && dependent_type_p (TREE_TYPE (id_expression)((contains_struct_check ((id_expression), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3782, __FUNCTION__))->typed.type)
)))))
3783 {
3784 /* If the qualifying type is non-dependent (and the name
3785 does not name a conversion operator to a dependent
3786 type), issue an error. */
3787 qualified_name_lookup_error (scope, id_expression, decl, location);
3788 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3789 }
3790 else if (!scope)
3791 {
3792 /* It may be resolved via Koenig lookup. */
3793 *idk = CP_ID_KIND_UNQUALIFIED;
3794 return id_expression;
3795 }
3796 else
3797 decl = id_expression;
3798 }
3799
3800 /* Remember that the name was used in the definition of
3801 the current class so that we can check later to see if
3802 the meaning would have been different after the class
3803 was entirely defined. */
3804 if (!scope && decl != error_mark_nodeglobal_trees[TI_ERROR_MARK] && identifier_p (id_expression))
3805 maybe_note_name_used_in_class (id_expression, decl);
3806
3807 /* A use in unevaluated operand might not be instantiated appropriately
3808 if tsubst_copy builds a dummy parm, or if we never instantiate a
3809 generic lambda, so mark it now. */
3810 if (processing_template_declscope_chain->x_processing_template_decl && cp_unevaluated_operand)
3811 mark_type_use (decl);
3812
3813 /* Disallow uses of local variables from containing functions, except
3814 within lambda-expressions. */
3815 if (outer_automatic_var_p (decl))
3816 {
3817 decl = process_outer_var_ref (decl, tf_warning_or_error);
3818 if (decl == error_mark_nodeglobal_trees[TI_ERROR_MARK])
3819 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3820 }
3821
3822 /* Also disallow uses of function parameters outside the function
3823 body, except inside an unevaluated context (i.e. decltype). */
3824 if (TREE_CODE (decl)((enum tree_code) (decl)->base.code) == PARM_DECL
3825 && DECL_CONTEXT (decl)((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3825, __FUNCTION__))->decl_minimal.context)
== NULL_TREE(tree) __null
3826 && !cp_unevaluated_operand)
3827 {
3828 *error_msg = G_("use of parameter outside function body")"use of parameter outside function body";
3829 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3830 }
3831 }
3832
3833 /* If we didn't find anything, or what we found was a type,
3834 then this wasn't really an id-expression. */
3835 if (TREE_CODE (decl)((enum tree_code) (decl)->base.code) == TEMPLATE_DECL
3836 && !DECL_FUNCTION_TEMPLATE_P (decl)(((enum tree_code) (decl)->base.code) == TEMPLATE_DECL &&
((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((decl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3836, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((decl
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3836, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)
)
3837 {
3838 *error_msg = G_("missing template arguments")"missing template arguments";
3839 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3840 }
3841 else if (TREE_CODE (decl)((enum tree_code) (decl)->base.code) == TYPE_DECL
3842 || TREE_CODE (decl)((enum tree_code) (decl)->base.code) == NAMESPACE_DECL)
3843 {
3844 *error_msg = G_("expected primary-expression")"expected primary-expression";
3845 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3846 }
3847
3848 /* If the name resolved to a template parameter, there is no
3849 need to look it up again later. */
3850 if ((TREE_CODE (decl)((enum tree_code) (decl)->base.code) == CONST_DECL && DECL_TEMPLATE_PARM_P (decl)(((contains_struct_check ((decl), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3850, __FUNCTION__))->decl_common.lang_flag_0) &&
(((enum tree_code) (decl)->base.code) == CONST_DECL || ((
enum tree_code) (decl)->base.code) == PARM_DECL || ((enum tree_code
) (decl)->base.code) == TYPE_DECL || ((enum tree_code) (decl
)->base.code) == TEMPLATE_DECL))
)
3851 || TREE_CODE (decl)((enum tree_code) (decl)->base.code) == TEMPLATE_PARM_INDEX)
3852 {
3853 tree r;
3854
3855 *idk = CP_ID_KIND_NONE;
3856 if (TREE_CODE (decl)((enum tree_code) (decl)->base.code) == TEMPLATE_PARM_INDEX)
3857 decl = TEMPLATE_PARM_DECL (decl)(((template_parm_index*)(tree_check ((decl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3857, __FUNCTION__, (TEMPLATE_PARM_INDEX))))->decl)
;
3858 r = DECL_INITIAL (decl)((contains_struct_check ((decl), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3858, __FUNCTION__))->decl_common.initial)
;
3859 if (CLASS_TYPE_P (TREE_TYPE (r))(((((enum tree_code) (((contains_struct_check ((r), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3859, __FUNCTION__))->typed.type))->base.code)) == RECORD_TYPE
|| (((enum tree_code) (((contains_struct_check ((r), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3859, __FUNCTION__))->typed.type))->base.code)) == UNION_TYPE
) && ((tree_class_check ((((contains_struct_check ((r
), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3859, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3859, __FUNCTION__))->type_common.lang_flag_5))
&& !CP_TYPE_CONST_P (TREE_TYPE (r))((cp_type_quals (((contains_struct_check ((r), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3859, __FUNCTION__))->typed.type)) & TYPE_QUAL_CONST
) != 0)
)
3860 {
3861 /* If the entity is a template parameter object for a template
3862 parameter of type T, the type of the expression is const T. */
3863 tree ctype = TREE_TYPE (r)((contains_struct_check ((r), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3863, __FUNCTION__))->typed.type)
;
3864 ctype = cp_build_qualified_type (ctype, (cp_type_quals (ctype)cp_build_qualified_type_real ((ctype), ((cp_type_quals (ctype
) | TYPE_QUAL_CONST)), tf_warning_or_error)
3865 | TYPE_QUAL_CONST))cp_build_qualified_type_real ((ctype), ((cp_type_quals (ctype
) | TYPE_QUAL_CONST)), tf_warning_or_error)
;
3866 r = build1 (VIEW_CONVERT_EXPR, ctype, r);
3867 }
3868 r = convert_from_reference (r);
3869 if (integral_constant_expression_p
3870 && !dependent_type_p (TREE_TYPE (decl)((contains_struct_check ((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3870, __FUNCTION__))->typed.type)
)
3871 && !(INTEGRAL_OR_ENUMERATION_TYPE_P (TREE_TYPE (r))(((enum tree_code) (((contains_struct_check ((r), (TS_TYPED),
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3871, __FUNCTION__))->typed.type))->base.code) == ENUMERAL_TYPE
|| (((enum tree_code) (((contains_struct_check ((r), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3871, __FUNCTION__))->typed.type))->base.code) == BOOLEAN_TYPE
|| ((enum tree_code) (((contains_struct_check ((r), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3871, __FUNCTION__))->typed.type))->base.code) == INTEGER_TYPE
))
))
3872 {
3873 if (!allow_non_integral_constant_expression_p)
3874 error ("template parameter %qD of type %qT is not allowed in "
3875 "an integral constant expression because it is not of "
3876 "integral or enumeration type", decl, TREE_TYPE (decl)((contains_struct_check ((decl), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3876, __FUNCTION__))->typed.type)
);
3877 *non_integral_constant_expression_p = true;
3878 }
3879 return r;
3880 }
3881 else
3882 {
3883 bool dependent_p = type_dependent_expression_p (decl);
3884
3885 /* If the declaration was explicitly qualified indicate
3886 that. The semantics of `A::f(3)' are different than
3887 `f(3)' if `f' is virtual. */
3888 *idk = (scope
3889 ? CP_ID_KIND_QUALIFIED
3890 : (TREE_CODE (decl)((enum tree_code) (decl)->base.code) == TEMPLATE_ID_EXPR
3891 ? CP_ID_KIND_TEMPLATE_ID
3892 : (dependent_p
3893 ? CP_ID_KIND_UNQUALIFIED_DEPENDENT
3894 : CP_ID_KIND_UNQUALIFIED)));
3895
3896 if (dependent_p
3897 && DECL_P (decl)(tree_code_type[(int) (((enum tree_code) (decl)->base.code
))] == tcc_declaration)
3898 && any_dependent_type_attributes_p (DECL_ATTRIBUTES (decl)((contains_struct_check ((decl), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3898, __FUNCTION__))->decl_common.attributes)
))
3899 /* Dependent type attributes on the decl mean that the TREE_TYPE is
3900 wrong, so just return the identifier. */
3901 return id_expression;
3902
3903 if (DECL_CLASS_TEMPLATE_P (decl)((((enum tree_code) (decl)->base.code) == TEMPLATE_DECL &&
((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((decl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3903, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((decl
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3903, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == TYPE_DECL) && (((enum tree_code) (((struct
tree_template_decl *)(const_cast<union tree_node *> ((
((tree_check ((decl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3903, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == TYPE_DECL && ((contains_struct_check ((
((struct tree_template_decl *)(const_cast<union tree_node *
> ((((tree_check ((decl), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3903, __FUNCTION__, (TEMPLATE_DECL))))))))->result), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3903, __FUNCTION__))->decl_common.lang_flag_2)))
)
3904 {
3905 error ("use of class template %qT as expression", decl);
3906 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3907 }
3908
3909 if (TREE_CODE (decl)((enum tree_code) (decl)->base.code) == TREE_LIST)
3910 {
3911 /* Ambiguous reference to base members. */
3912 error ("request for member %qD is ambiguous in "
3913 "multiple inheritance lattice", id_expression);
3914 print_candidates (decl);
3915 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3916 }
3917
3918 /* Mark variable-like entities as used. Functions are similarly
3919 marked either below or after overload resolution. */
3920 if ((VAR_P (decl)(((enum tree_code) (decl)->base.code) == VAR_DECL)
3921 || TREE_CODE (decl)((enum tree_code) (decl)->base.code) == PARM_DECL
3922 || TREE_CODE (decl)((enum tree_code) (decl)->base.code) == CONST_DECL
3923 || TREE_CODE (decl)((enum tree_code) (decl)->base.code) == RESULT_DECL)
3924 && !mark_used (decl))
3925 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3926
3927 /* Only certain kinds of names are allowed in constant
3928 expression. Template parameters have already
3929 been handled above. */
3930 if (! error_operand_p (decl)((decl) == global_trees[TI_ERROR_MARK] || ((decl) && (
(contains_struct_check (((decl)), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3930, __FUNCTION__))->typed.type) == global_trees[TI_ERROR_MARK
]))
3931 && !dependent_p
3932 && integral_constant_expression_p
3933 && !decl_constant_var_p (decl)
3934 && TREE_CODE (decl)((enum tree_code) (decl)->base.code) != CONST_DECL
3935 && !builtin_valid_in_constant_expr_p (decl)
3936 && !concept_check_p (decl))
3937 {
3938 if (!allow_non_integral_constant_expression_p)
3939 {
3940 error ("%qD cannot appear in a constant-expression", decl);
3941 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
3942 }
3943 *non_integral_constant_expression_p = true;
3944 }
3945
3946 if (tree wrap = maybe_get_tls_wrapper_call (decl))
3947 /* Replace an evaluated use of the thread_local variable with
3948 a call to its wrapper. */
3949 decl = wrap;
3950 else if (TREE_CODE (decl)((enum tree_code) (decl)->base.code) == TEMPLATE_ID_EXPR
3951 && !dependent_p
3952 && variable_template_p (TREE_OPERAND (decl, 0)(*((const_cast<tree*> (tree_operand_check ((decl), (0),
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3952, __FUNCTION__)))))
)
3953 && !concept_check_p (decl))
3954 {
3955 decl = finish_template_variable (decl);
3956 mark_used (decl);
3957 decl = convert_from_reference (decl);
3958 }
3959 else if (concept_check_p (decl))
3960 {
3961 /* Nothing more to do. All of the analysis for concept checks
3962 is done by build_conept_id, called from the parser. */
3963 }
3964 else if (scope)
3965 {
3966 if (TREE_CODE (decl)((enum tree_code) (decl)->base.code) == SCOPE_REF)
3967 {
3968 gcc_assert (same_type_p (scope, TREE_OPERAND (decl, 0)))((void)(!(comptypes ((scope), ((*((const_cast<tree*> (tree_operand_check
((decl), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3968, __FUNCTION__)))))), 0)) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3968, __FUNCTION__), 0 : 0))
;
3969 decl = TREE_OPERAND (decl, 1)(*((const_cast<tree*> (tree_operand_check ((decl), (1),
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 3969, __FUNCTION__)))))
;
3970 }
3971
3972 decl = (adjust_result_of_qualified_name_lookup
3973 (decl, scope, current_nonlambda_class_type()));
3974
3975 if (TREE_CODE (decl)((enum tree_code) (decl)->base.code) == FUNCTION_DECL)
3976 mark_used (decl);
3977
3978 cp_warn_deprecated_use_scopes (scope);
3979
3980 if (TYPE_P (scope)(tree_code_type[(int) (((enum tree_code) (scope)->base.code
))] == tcc_type)
)
3981 decl = finish_qualified_id_expr (scope,
3982 decl,
3983 done,
3984 address_p,
3985 template_p,
3986 template_arg_p,
3987 tf_warning_or_error);
3988 else
3989 decl = convert_from_reference (decl);
3990 }
3991 else if (TREE_CODE (decl)((enum tree_code) (decl)->base.code) == FIELD_DECL)
3992 {
3993 /* Since SCOPE is NULL here, this is an unqualified name.
3994 Access checking has been performed during name lookup
3995 already. Turn off checking to avoid duplicate errors. */
3996 push_deferring_access_checks (dk_no_check);
3997 decl = finish_non_static_data_member (decl, NULL_TREE(tree) __null,
3998 /*qualifying_scope=*/NULL_TREE(tree) __null);
3999 pop_deferring_access_checks ();
4000 }
4001 else if (is_overloaded_fn (decl))
4002 {
4003 /* We only need to look at the first function,
4004 because all the fns share the attribute we're
4005 concerned with (all member fns or all non-members). */
4006 tree first_fn = get_first_fn (decl);
4007 first_fn = STRIP_TEMPLATE (first_fn)(((enum tree_code) (first_fn)->base.code) == TEMPLATE_DECL
? ((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((first_fn), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4007, __FUNCTION__, (TEMPLATE_DECL))))))))->result : first_fn
)
;
4008
4009 /* [basic.def.odr]: "A function whose name appears as a
4010 potentially-evaluated expression is odr-used if it is the unique
4011 lookup result".
4012
4013 But only mark it if it's a complete postfix-expression; in a call,
4014 ADL might select a different function, and we'll call mark_used in
4015 build_over_call. */
4016 if (done
4017 && !really_overloaded_fn (decl)
4018 && !mark_used (first_fn))
4019 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
4020
4021 if (!template_arg_p
4022 && (TREE_CODE (first_fn)((enum tree_code) (first_fn)->base.code) == USING_DECL
4023 || (TREE_CODE (first_fn)((enum tree_code) (first_fn)->base.code) == FUNCTION_DECL
4024 && DECL_FUNCTION_MEMBER_P (first_fn)((((enum tree_code) (((contains_struct_check ((first_fn), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4024, __FUNCTION__))->typed.type))->base.code) == METHOD_TYPE
) || (__extension__ ({ struct lang_decl *lt = ((contains_struct_check
(((((enum tree_code) (first_fn)->base.code) == TEMPLATE_DECL
? ((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((first_fn), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4024, __FUNCTION__, (TEMPLATE_DECL))))))))->result : first_fn
)), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4024, __FUNCTION__))->decl_common.lang_specific); if (!(
((enum tree_code) (first_fn)->base.code) == FUNCTION_DECL ||
(((enum tree_code) (first_fn)->base.code) == TEMPLATE_DECL
&& ((struct tree_template_decl *)(const_cast<union
tree_node *> ((((tree_check ((first_fn), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4024, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((first_fn
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4024, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)) || lt->u.base.selector != lds_fn
) lang_check_failed ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4024, __FUNCTION__); &lt->u.fn; })->static_function
))
4025 && !shared_member_p (decl))))
4026 {
4027 /* A set of member functions. */
4028 decl = maybe_dummy_object (DECL_CONTEXT (first_fn)((contains_struct_check ((first_fn), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4028, __FUNCTION__))->decl_minimal.context)
, 0);
4029 return finish_class_member_access_expr (decl, id_expression,
4030 /*template_p=*/false,
4031 tf_warning_or_error);
4032 }
4033
4034 decl = baselink_for_fns (decl);
4035 }
4036 else
4037 {
4038 if (DECL_P (decl)(tree_code_type[(int) (((enum tree_code) (decl)->base.code
))] == tcc_declaration)
&& DECL_NONLOCAL (decl)((contains_struct_check ((decl), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4038, __FUNCTION__))->decl_common.nonlocal_flag)
4039 && DECL_CLASS_SCOPE_P (decl)(((contains_struct_check ((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4039, __FUNCTION__))->decl_minimal.context) && (
tree_code_type[(int) (((enum tree_code) (((contains_struct_check
((decl), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4039, __FUNCTION__))->decl_minimal.context))->base.code
))] == tcc_type))
)
4040 {
4041 tree context = context_for_name_lookup (decl);
4042 if (context != current_class_typescope_chain->class_type)
4043 {
4044 tree path = currently_open_derived_class (context);
4045 if (!path)
4046 /* PATH can be null for using an enum of an unrelated
4047 class; we checked its access in lookup_using_decl.
4048
4049 ??? Should this case make a clone instead, like
4050 handle_using_decl? */
4051 gcc_assert (TREE_CODE (decl) == CONST_DECL)((void)(!(((enum tree_code) (decl)->base.code) == CONST_DECL
) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4051, __FUNCTION__), 0 : 0))
;
4052 else
4053 perform_or_defer_access_check (TYPE_BINFO (path)((tree_check3 ((path), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4053, __FUNCTION__, (RECORD_TYPE), (UNION_TYPE), (QUAL_UNION_TYPE
)))->type_non_common.maxval)
,
4054 decl, decl,
4055 tf_warning_or_error);
4056 }
4057 }
4058
4059 decl = convert_from_reference (decl);
4060 }
4061 }
4062
4063 return cp_expr (decl, location);
4064}
4065
4066/* As per finish_id_expression_1, but adding a wrapper node
4067 around the result if needed to express LOCATION. */
4068
4069cp_expr
4070finish_id_expression (tree id_expression,
4071 tree decl,
4072 tree scope,
4073 cp_id_kind *idk,
4074 bool integral_constant_expression_p,
4075 bool allow_non_integral_constant_expression_p,
4076 bool *non_integral_constant_expression_p,
4077 bool template_p,
4078 bool done,
4079 bool address_p,
4080 bool template_arg_p,
4081 const char **error_msg,
4082 location_t location)
4083{
4084 cp_expr result
4085 = finish_id_expression_1 (id_expression, decl, scope, idk,
4086 integral_constant_expression_p,
4087 allow_non_integral_constant_expression_p,
4088 non_integral_constant_expression_p,
4089 template_p, done, address_p, template_arg_p,
4090 error_msg, location);
4091 return result.maybe_add_location_wrapper ();
4092}
4093
4094/* Implement the __typeof keyword: Return the type of EXPR, suitable for
4095 use as a type-specifier. */
4096
4097tree
4098finish_typeof (tree expr)
4099{
4100 tree type;
4101
4102 if (type_dependent_expression_p (expr))
4103 {
4104 type = cxx_make_type (TYPEOF_TYPE);
4105 TYPEOF_TYPE_EXPR (type)(((tree_class_check (((tree_check ((type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4105, __FUNCTION__, (TYPEOF_TYPE)))), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4105, __FUNCTION__))->type_non_common.values))
= expr;
4106 SET_TYPE_STRUCTURAL_EQUALITY (type)(((tree_class_check ((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4106, __FUNCTION__))->type_common.canonical) = (tree) __null
)
;
4107
4108 return type;
4109 }
4110
4111 expr = mark_type_use (expr);
4112
4113 type = unlowered_expr_type (expr);
4114
4115 if (!type || type == unknown_type_nodecp_global_trees[CPTI_UNKNOWN_TYPE])
4116 {
4117 error ("type of %qE is unknown", expr);
4118 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
4119 }
4120
4121 return type;
4122}
4123
4124/* Implement the __underlying_type keyword: Return the underlying
4125 type of TYPE, suitable for use as a type-specifier. */
4126
4127tree
4128finish_underlying_type (tree type)
4129{
4130 tree underlying_type;
4131
4132 if (processing_template_declscope_chain->x_processing_template_decl)
4133 {
4134 underlying_type = cxx_make_type (UNDERLYING_TYPE);
4135 UNDERLYING_TYPE_TYPE (underlying_type)(((tree_class_check (((tree_check ((underlying_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4135, __FUNCTION__, (UNDERLYING_TYPE)))), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4135, __FUNCTION__))->type_non_common.values))
= type;
4136 SET_TYPE_STRUCTURAL_EQUALITY (underlying_type)(((tree_class_check ((underlying_type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4136, __FUNCTION__))->type_common.canonical) = (tree) __null
)
;
4137
4138 return underlying_type;
4139 }
4140
4141 if (!complete_type_or_else (type, NULL_TREE(tree) __null))
4142 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
4143
4144 if (TREE_CODE (type)((enum tree_code) (type)->base.code) != ENUMERAL_TYPE)
4145 {
4146 error ("%qT is not an enumeration type", type);
4147 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
4148 }
4149
4150 underlying_type = ENUM_UNDERLYING_TYPE (type)((contains_struct_check (((tree_check ((type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4150, __FUNCTION__, (ENUMERAL_TYPE)))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4150, __FUNCTION__))->typed.type)
;
4151
4152 /* Fixup necessary in this case because ENUM_UNDERLYING_TYPE
4153 includes TYPE_MIN_VALUE and TYPE_MAX_VALUE information.
4154 See finish_enum_value_list for details. */
4155 if (!ENUM_FIXED_UNDERLYING_TYPE_P (type)(((tree_class_check ((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4155, __FUNCTION__))->type_common.lang_flag_5))
)
4156 underlying_type
4157 = c_common_type_for_mode (TYPE_MODE (underlying_type)((((enum tree_code) ((tree_class_check ((underlying_type), (tcc_type
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4157, __FUNCTION__)))->base.code) == VECTOR_TYPE) ? vector_type_mode
(underlying_type) : (underlying_type)->type_common.mode)
,
4158 TYPE_UNSIGNED (underlying_type)((tree_class_check ((underlying_type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4158, __FUNCTION__))->base.u.bits.unsigned_flag)
);
4159
4160 return underlying_type;
4161}
4162
4163/* Implement the __direct_bases keyword: Return the direct base classes
4164 of type. */
4165
4166tree
4167calculate_direct_bases (tree type, tsubst_flags_t complain)
4168{
4169 if (!complete_type_or_maybe_complain (type, NULL_TREE(tree) __null, complain)
4170 || !NON_UNION_CLASS_TYPE_P (type)(((enum tree_code) (type)->base.code) == RECORD_TYPE &&
((tree_class_check ((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4170, __FUNCTION__))->type_common.lang_flag_5))
)
4171 return make_tree_vec (0);
4172
4173 releasing_vec vector;
4174 vec<tree, va_gc> *base_binfos = BINFO_BASE_BINFOS (TYPE_BINFO (type))(&(tree_check ((((tree_check3 ((type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4174, __FUNCTION__, (RECORD_TYPE), (UNION_TYPE), (QUAL_UNION_TYPE
)))->type_non_common.maxval)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4174, __FUNCTION__, (TREE_BINFO)))->binfo.base_binfos)
;
4175 tree binfo;
4176 unsigned i;
4177
4178 /* Virtual bases are initialized first */
4179 for (i = 0; base_binfos->iterate (i, &binfo); i++)
4180 if (BINFO_VIRTUAL_P (binfo)((tree_check ((binfo), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4180, __FUNCTION__, (TREE_BINFO)))->base.static_flag)
)
4181 vec_safe_push (vector, binfo);
4182
4183 /* Now non-virtuals */
4184 for (i = 0; base_binfos->iterate (i, &binfo); i++)
4185 if (!BINFO_VIRTUAL_P (binfo)((tree_check ((binfo), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4185, __FUNCTION__, (TREE_BINFO)))->base.static_flag)
)
4186 vec_safe_push (vector, binfo);
4187
4188 tree bases_vec = make_tree_vec (vector->length ());
4189
4190 for (i = 0; i < vector->length (); ++i)
4191 TREE_VEC_ELT (bases_vec, i)(*((const_cast<tree *> (tree_vec_elt_check ((bases_vec)
, (i), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4191, __FUNCTION__)))))
= BINFO_TYPE ((*vector)[i])((contains_struct_check (((tree_check (((*vector)[i]), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4191, __FUNCTION__, (TREE_BINFO)))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4191, __FUNCTION__))->typed.type)
;
4192
4193 return bases_vec;
4194}
4195
4196/* Implement the __bases keyword: Return the base classes
4197 of type */
4198
4199/* Find morally non-virtual base classes by walking binfo hierarchy */
4200/* Virtual base classes are handled separately in finish_bases */
4201
4202static tree
4203dfs_calculate_bases_pre (tree binfo, void * /*data_*/)
4204{
4205 /* Don't walk bases of virtual bases */
4206 return BINFO_VIRTUAL_P (binfo)((tree_check ((binfo), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4206, __FUNCTION__, (TREE_BINFO)))->base.static_flag)
? dfs_skip_bases((tree)1) : NULL_TREE(tree) __null;
4207}
4208
4209static tree
4210dfs_calculate_bases_post (tree binfo, void *data_)
4211{
4212 vec<tree, va_gc> **data = ((vec<tree, va_gc> **) data_);
4213 if (!BINFO_VIRTUAL_P (binfo)((tree_check ((binfo), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4213, __FUNCTION__, (TREE_BINFO)))->base.static_flag)
)
4214 vec_safe_push (*data, BINFO_TYPE (binfo)((contains_struct_check (((tree_check ((binfo), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4214, __FUNCTION__, (TREE_BINFO)))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4214, __FUNCTION__))->typed.type)
);
4215 return NULL_TREE(tree) __null;
4216}
4217
4218/* Calculates the morally non-virtual base classes of a class */
4219static vec<tree, va_gc> *
4220calculate_bases_helper (tree type)
4221{
4222 vec<tree, va_gc> *vector = make_tree_vector ();
4223
4224 /* Now add non-virtual base classes in order of construction */
4225 if (TYPE_BINFO (type)((tree_check3 ((type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4225, __FUNCTION__, (RECORD_TYPE), (UNION_TYPE), (QUAL_UNION_TYPE
)))->type_non_common.maxval)
)
4226 dfs_walk_all (TYPE_BINFO (type)((tree_check3 ((type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4226, __FUNCTION__, (RECORD_TYPE), (UNION_TYPE), (QUAL_UNION_TYPE
)))->type_non_common.maxval)
,
4227 dfs_calculate_bases_pre, dfs_calculate_bases_post, &vector);
4228 return vector;
4229}
4230
4231tree
4232calculate_bases (tree type, tsubst_flags_t complain)
4233{
4234 if (!complete_type_or_maybe_complain (type, NULL_TREE(tree) __null, complain)
4235 || !NON_UNION_CLASS_TYPE_P (type)(((enum tree_code) (type)->base.code) == RECORD_TYPE &&
((tree_class_check ((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4235, __FUNCTION__))->type_common.lang_flag_5))
)
4236 return make_tree_vec (0);
4237
4238 releasing_vec vector;
4239 tree bases_vec = NULL_TREE(tree) __null;
4240 unsigned i;
4241 vec<tree, va_gc> *vbases;
4242 tree binfo;
4243
4244 /* First go through virtual base classes */
4245 for (vbases = CLASSTYPE_VBASECLASSES (type)((((tree_class_check ((type), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4245, __FUNCTION__))->type_with_lang_specific.lang_specific
))->vbases)
, i = 0;
4246 vec_safe_iterate (vbases, i, &binfo); i++)
4247 {
4248 releasing_vec vbase_bases
4249 = calculate_bases_helper (BINFO_TYPE (binfo)((contains_struct_check (((tree_check ((binfo), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4249, __FUNCTION__, (TREE_BINFO)))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4249, __FUNCTION__))->typed.type)
);
4250 vec_safe_splice (vector, vbase_bases);
4251 }
4252
4253 /* Now for the non-virtual bases */
4254 releasing_vec nonvbases = calculate_bases_helper (type);
4255 vec_safe_splice (vector, nonvbases);
4256
4257 /* Note that during error recovery vector->length can even be zero. */
4258 if (vector->length () > 1)
4259 {
4260 /* Last element is entire class, so don't copy */
4261 bases_vec = make_tree_vec (vector->length () - 1);
4262
4263 for (i = 0; i < vector->length () - 1; ++i)
4264 TREE_VEC_ELT (bases_vec, i)(*((const_cast<tree *> (tree_vec_elt_check ((bases_vec)
, (i), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4264, __FUNCTION__)))))
= (*vector)[i];
4265 }
4266 else
4267 bases_vec = make_tree_vec (0);
4268
4269 return bases_vec;
4270}
4271
4272tree
4273finish_bases (tree type, bool direct)
4274{
4275 tree bases = NULL_TREE(tree) __null;
4276
4277 if (!processing_template_declscope_chain->x_processing_template_decl)
4278 {
4279 /* Parameter packs can only be used in templates */
4280 error ("parameter pack %<__bases%> only valid in template declaration");
4281 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
4282 }
4283
4284 bases = cxx_make_type (BASES);
4285 BASES_TYPE (bases)(((tree_class_check (((tree_check ((bases), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4285, __FUNCTION__, (BASES)))), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4285, __FUNCTION__))->type_non_common.values))
= type;
4286 BASES_DIRECT (bases)((tree_not_check2 (((tree_check ((bases), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4286, __FUNCTION__, (BASES)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4286, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_0)
= direct;
4287 SET_TYPE_STRUCTURAL_EQUALITY (bases)(((tree_class_check ((bases), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4287, __FUNCTION__))->type_common.canonical) = (tree) __null
)
;
4288
4289 return bases;
4290}
4291
4292/* Perform C++-specific checks for __builtin_offsetof before calling
4293 fold_offsetof. */
4294
4295tree
4296finish_offsetof (tree object_ptr, tree expr, location_t loc)
4297{
4298 /* If we're processing a template, we can't finish the semantics yet.
4299 Otherwise we can fold the entire expression now. */
4300 if (processing_template_declscope_chain->x_processing_template_decl)
4301 {
4302 expr = build2 (OFFSETOF_EXPR, size_type_nodeglobal_trees[TI_SIZE_TYPE], expr, object_ptr);
4303 SET_EXPR_LOCATION (expr, loc)(expr_check (((expr)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4303, __FUNCTION__))->exp.locus = (loc)
;
4304 return expr;
4305 }
4306
4307 if (expr == error_mark_nodeglobal_trees[TI_ERROR_MARK])
4308 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
4309
4310 if (TREE_CODE (expr)((enum tree_code) (expr)->base.code) == PSEUDO_DTOR_EXPR)
4311 {
4312 error ("cannot apply %<offsetof%> to destructor %<~%T%>",
4313 TREE_OPERAND (expr, 2)(*((const_cast<tree*> (tree_operand_check ((expr), (2),
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4313, __FUNCTION__)))))
);
4314 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
4315 }
4316 if (FUNC_OR_METHOD_TYPE_P (TREE_TYPE (expr))(((enum tree_code) (((contains_struct_check ((expr), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4316, __FUNCTION__))->typed.type))->base.code) == FUNCTION_TYPE
|| ((enum tree_code) (((contains_struct_check ((expr), (TS_TYPED
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4316, __FUNCTION__))->typed.type))->base.code) == METHOD_TYPE
)
4317 || TREE_TYPE (expr)((contains_struct_check ((expr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4317, __FUNCTION__))->typed.type)
== unknown_type_nodecp_global_trees[CPTI_UNKNOWN_TYPE])
4318 {
4319 while (TREE_CODE (expr)((enum tree_code) (expr)->base.code) == COMPONENT_REF
4320 || TREE_CODE (expr)((enum tree_code) (expr)->base.code) == COMPOUND_EXPR)
4321 expr = TREE_OPERAND (expr, 1)(*((const_cast<tree*> (tree_operand_check ((expr), (1),
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4321, __FUNCTION__)))))
;
4322
4323 if (DECL_P (expr)(tree_code_type[(int) (((enum tree_code) (expr)->base.code
))] == tcc_declaration)
)
4324 {
4325 error ("cannot apply %<offsetof%> to member function %qD", expr);
4326 inform (DECL_SOURCE_LOCATION (expr)((contains_struct_check ((expr), (TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4326, __FUNCTION__))->decl_minimal.locus)
, "declared here");
4327 }
4328 else
4329 error ("cannot apply %<offsetof%> to member function");
4330 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
4331 }
4332 if (TREE_CODE (expr)((enum tree_code) (expr)->base.code) == CONST_DECL)
4333 {
4334 error ("cannot apply %<offsetof%> to an enumerator %qD", expr);
4335 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
4336 }
4337 if (REFERENCE_REF_P (expr)((((enum tree_code) (expr)->base.code) == INDIRECT_REF) &&
((contains_struct_check (((*((const_cast<tree*> (tree_operand_check
((expr), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4337, __FUNCTION__)))))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4337, __FUNCTION__))->typed.type) && (((enum tree_code
) (((contains_struct_check (((*((const_cast<tree*> (tree_operand_check
(((expr)), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4337, __FUNCTION__)))))), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4337, __FUNCTION__))->typed.type))->base.code) == REFERENCE_TYPE
))
)
4338 expr = TREE_OPERAND (expr, 0)(*((const_cast<tree*> (tree_operand_check ((expr), (0),
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4338, __FUNCTION__)))))
;
4339 if (!complete_type_or_else (TREE_TYPE (TREE_TYPE (object_ptr))((contains_struct_check ((((contains_struct_check ((object_ptr
), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4339, __FUNCTION__))->typed.type)), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4339, __FUNCTION__))->typed.type)
, object_ptr))
4340 return error_mark_nodeglobal_trees[TI_ERROR_MARK];
4341 if (warn_invalid_offsetofglobal_options.x_warn_invalid_offsetof
4342 && CLASS_TYPE_P (TREE_TYPE (TREE_TYPE (object_ptr)))(((((enum tree_code) (((contains_struct_check ((((contains_struct_check
((object_ptr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4342, __FUNCTION__))->typed.type)), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4342, __FUNCTION__))->typed.type))->base.code)) == RECORD_TYPE
|| (((enum tree_code) (((contains_struct_check ((((contains_struct_check
((object_ptr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4342, __FUNCTION__))->typed.type)), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4342, __FUNCTION__))->typed.type))->base.code)) == UNION_TYPE
) && ((tree_class_check ((((contains_struct_check (((
(contains_struct_check ((object_ptr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4342, __FUNCTION__))->typed.type)), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4342, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4342, __FUNCTION__))->type_common.lang_flag_5))
4343 && CLASSTYPE_NON_STD_LAYOUT (TREE_TYPE (TREE_TYPE (object_ptr)))((((tree_class_check ((((contains_struct_check ((((contains_struct_check
((object_ptr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4343, __FUNCTION__))->typed.type)), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4343, __FUNCTION__))->typed.type)), (tcc_type), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4343, __FUNCTION__))->type_with_lang_specific.lang_specific
))->non_std_layout)
4344 && cp_unevaluated_operand == 0)
4345 warning_at (loc, OPT_Winvalid_offsetof, "%<offsetof%> within "
4346 "non-standard-layout type %qT is conditionally-supported",
4347 TREE_TYPE (TREE_TYPE (object_ptr))((contains_struct_check ((((contains_struct_check ((object_ptr
), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4347, __FUNCTION__))->typed.type)), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4347, __FUNCTION__))->typed.type)
);
4348 return fold_offsetof (expr);
4349}
4350
4351/* Replace the AGGR_INIT_EXPR at *TP with an equivalent CALL_EXPR. This
4352 function is broken out from the above for the benefit of the tree-ssa
4353 project. */
4354
4355void
4356simplify_aggr_init_expr (tree *tp)
4357{
4358 tree aggr_init_expr = *tp;
4359
4360 /* Form an appropriate CALL_EXPR. */
4361 tree fn = AGGR_INIT_EXPR_FN (aggr_init_expr)(*((const_cast<tree*> (tree_operand_check (((tree_check
((aggr_init_expr), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4361, __FUNCTION__, (AGGR_INIT_EXPR)))), (1), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4361, __FUNCTION__)))))
;
4362 tree slot = AGGR_INIT_EXPR_SLOT (aggr_init_expr)(*((const_cast<tree*> (tree_operand_check (((tree_check
((aggr_init_expr), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4362, __FUNCTION__, (AGGR_INIT_EXPR)))), (2), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4362, __FUNCTION__)))))
;
4363 tree type = TREE_TYPE (slot)((contains_struct_check ((slot), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4363, __FUNCTION__))->typed.type)
;
4364
4365 tree call_expr;
4366 enum style_t { ctor, arg, pcc } style;
4367
4368 if (AGGR_INIT_VIA_CTOR_P (aggr_init_expr)((tree_not_check2 (((tree_check ((aggr_init_expr), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4368, __FUNCTION__, (AGGR_INIT_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4368, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_0)
)
4369 style = ctor;
4370#ifdef PCC_STATIC_STRUCT_RETURN
4371 else if (1)
4372 style = pcc;
4373#endif
4374 else
4375 {
4376 gcc_assert (TREE_ADDRESSABLE (type))((void)(!(((type)->base.addressable_flag)) ? fancy_abort (
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4376, __FUNCTION__), 0 : 0))
;
4377 style = arg;
4378 }
4379
4380 call_expr = build_call_array_loc (input_location,
4381 TREE_TYPE (TREE_TYPE (TREE_TYPE (fn)))((contains_struct_check ((((contains_struct_check ((((contains_struct_check
((fn), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4381, __FUNCTION__))->typed.type)), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4381, __FUNCTION__))->typed.type)), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4381, __FUNCTION__))->typed.type)
,
4382 fn,
4383 aggr_init_expr_nargs (aggr_init_expr)(((int)((unsigned long) (*tree_int_cst_elt_check (((tree_class_check
((aggr_init_expr), (tcc_vl_exp), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4383, __FUNCTION__))->exp.operands[0]), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4383, __FUNCTION__)))) - 3)
,
4384 AGGR_INIT_EXPR_ARGP (aggr_init_expr)(&((*((const_cast<tree*> (tree_operand_check (((tree_check
((aggr_init_expr), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4384, __FUNCTION__, (AGGR_INIT_EXPR)))), (0), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4384, __FUNCTION__)))))) + 3)
);
4385 TREE_NOTHROW (call_expr)((call_expr)->base.nothrow_flag) = TREE_NOTHROW (aggr_init_expr)((aggr_init_expr)->base.nothrow_flag);
4386 CALL_FROM_THUNK_P (call_expr)((tree_check ((call_expr), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4386, __FUNCTION__, (CALL_EXPR)))->base.protected_flag)
= AGGR_INIT_FROM_THUNK_P (aggr_init_expr)((tree_check ((aggr_init_expr), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4386, __FUNCTION__, (AGGR_INIT_EXPR)))->base.protected_flag
)
;
4387 CALL_EXPR_OPERATOR_SYNTAX (call_expr)((tree_not_check2 (((tree_check2 (((call_expr)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4387, __FUNCTION__, (CALL_EXPR), (AGGR_INIT_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4387, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_6)
4388 = CALL_EXPR_OPERATOR_SYNTAX (aggr_init_expr)((tree_not_check2 (((tree_check2 (((aggr_init_expr)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4388, __FUNCTION__, (CALL_EXPR), (AGGR_INIT_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4388, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_6)
;
4389 CALL_EXPR_ORDERED_ARGS (call_expr)((tree_not_check2 (((tree_check2 (((call_expr)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4389, __FUNCTION__, (CALL_EXPR), (AGGR_INIT_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4389, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_3)
= CALL_EXPR_ORDERED_ARGS (aggr_init_expr)((tree_not_check2 (((tree_check2 (((aggr_init_expr)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4389, __FUNCTION__, (CALL_EXPR), (AGGR_INIT_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4389, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_3)
;
4390 CALL_EXPR_REVERSE_ARGS (call_expr)((tree_not_check2 (((tree_check2 (((call_expr)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4390, __FUNCTION__, (CALL_EXPR), (AGGR_INIT_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4390, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_5)
= CALL_EXPR_REVERSE_ARGS (aggr_init_expr)((tree_not_check2 (((tree_check2 (((aggr_init_expr)), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4390, __FUNCTION__, (CALL_EXPR), (AGGR_INIT_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4390, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_5)
;
4391
4392 if (style == ctor)
4393 {
4394 /* Replace the first argument to the ctor with the address of the
4395 slot. */
4396 cxx_mark_addressable (slot);
4397 CALL_EXPR_ARG (call_expr, 0)(*((const_cast<tree*> (tree_operand_check (((tree_check
((call_expr), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4397, __FUNCTION__, (CALL_EXPR)))), ((0) + 3), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4397, __FUNCTION__)))))
=
4398 build1 (ADDR_EXPR, build_pointer_type (type), slot);
4399 }
4400 else if (style == arg)
4401 {
4402 /* Just mark it addressable here, and leave the rest to
4403 expand_call{,_inline}. */
4404 cxx_mark_addressable (slot);
4405 CALL_EXPR_RETURN_SLOT_OPT (call_expr)((tree_check ((call_expr), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4405, __FUNCTION__, (CALL_EXPR)))->base.private_flag)
= true;
4406 call_expr = build2 (INIT_EXPR, TREE_TYPE (call_expr)((contains_struct_check ((call_expr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4406, __FUNCTION__))->typed.type)
, slot, call_expr);
4407 }
4408 else if (style == pcc)
4409 {
4410 /* If we're using the non-reentrant PCC calling convention, then we
4411 need to copy the returned value out of the static buffer into the
4412 SLOT. */
4413 push_deferring_access_checks (dk_no_check);
4414 call_expr = build_aggr_init (slot, call_expr,
4415 DIRECT_BIND(1 << 3) | LOOKUP_ONLYCONVERTING(1 << 2),
4416 tf_warning_or_error);
4417 pop_deferring_access_checks ();
4418 call_expr = build2 (COMPOUND_EXPR, TREE_TYPE (slot)((contains_struct_check ((slot), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4418, __FUNCTION__))->typed.type)
, call_expr, slot);
4419 }
4420
4421 if (AGGR_INIT_ZERO_FIRST (aggr_init_expr)((tree_not_check2 (((tree_check ((aggr_init_expr), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4421, __FUNCTION__, (AGGR_INIT_EXPR)))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4421, __FUNCTION__, (TREE_VEC), (SSA_NAME)))->base.u.bits
.lang_flag_2)
)
4422 {
4423 tree init = build_zero_init (type, NULL_TREE(tree) __null,
4424 /*static_storage_p=*/false);
4425 init = build2 (INIT_EXPR, void_type_nodeglobal_trees[TI_VOID_TYPE], slot, init);
4426 call_expr = build2 (COMPOUND_EXPR, TREE_TYPE (call_expr)((contains_struct_check ((call_expr), (TS_TYPED), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4426, __FUNCTION__))->typed.type)
,
4427 init, call_expr);
4428 }
4429
4430 *tp = call_expr;
4431}
4432
4433/* Emit all thunks to FN that should be emitted when FN is emitted. */
4434
4435void
4436emit_associated_thunks (tree fn)
4437{
4438 /* When we use vcall offsets, we emit thunks with the virtual
4439 functions to which they thunk. The whole point of vcall offsets
4440 is so that you can know statically the entire set of thunks that
4441 will ever be needed for a given virtual function, thereby
4442 enabling you to output all the thunks with the function itself. */
4443 if (DECL_VIRTUAL_P (fn)((contains_struct_check ((fn), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4443, __FUNCTION__))->decl_common.virtual_flag)
4444 /* Do not emit thunks for extern template instantiations. */
4445 && ! DECL_REALLY_EXTERN (fn)(((contains_struct_check ((fn), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4445, __FUNCTION__))->decl_common.decl_flag_1) &&
(!((contains_struct_check ((fn), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4445, __FUNCTION__))->decl_common.lang_specific) || !(((
contains_struct_check ((fn), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4445, __FUNCTION__))->decl_common.lang_specific)->u.base
.not_really_extern)))
)
4446 {
4447 tree thunk;
4448
4449 for (thunk = DECL_THUNKS (fn)(((contains_struct_check ((fn), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4449, __FUNCTION__))->decl_common.virtual_flag) ? __extension__
({ struct lang_decl *lt = ((contains_struct_check (((((enum tree_code
) (fn)->base.code) == TEMPLATE_DECL ? ((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((fn),
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4449, __FUNCTION__, (TEMPLATE_DECL))))))))->result : fn)
), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4449, __FUNCTION__))->decl_common.lang_specific); if (!(
((enum tree_code) (fn)->base.code) == FUNCTION_DECL || (((
enum tree_code) (fn)->base.code) == TEMPLATE_DECL &&
((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((fn), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4449, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((fn),
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4449, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)) || lt->u.base.selector != lds_fn
) lang_check_failed ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4449, __FUNCTION__); &lt->u.fn; })->context : (tree
) __null)
; thunk; thunk = DECL_CHAIN (thunk)(((contains_struct_check (((contains_struct_check ((thunk), (
TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4449, __FUNCTION__))), (TS_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4449, __FUNCTION__))->common.chain))
)
4450 {
4451 if (!THUNK_ALIAS (thunk)(((contains_struct_check (((tree_check ((thunk), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4451, __FUNCTION__, (FUNCTION_DECL)))), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4451, __FUNCTION__))->decl_common.lang_specific)->u.min
.template_info)
)
4452 {
4453 use_thunk (thunk, /*emit_p=*/1);
4454 if (DECL_RESULT_THUNK_P (thunk)((((enum tree_code) (thunk)->base.code) == FUNCTION_DECL &&
((contains_struct_check ((thunk), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4454, __FUNCTION__))->decl_common.lang_specific) &&
__extension__ ({ struct lang_decl *lt = ((contains_struct_check
(((((enum tree_code) (thunk)->base.code) == TEMPLATE_DECL
? ((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((thunk), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4454, __FUNCTION__, (TEMPLATE_DECL))))))))->result : thunk
)), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4454, __FUNCTION__))->decl_common.lang_specific); if (!(
((enum tree_code) (thunk)->base.code) == FUNCTION_DECL || (
((enum tree_code) (thunk)->base.code) == TEMPLATE_DECL &&
((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((thunk), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4454, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((thunk
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4454, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)) || lt->u.base.selector != lds_fn
) lang_check_failed ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4454, __FUNCTION__); &lt->u.fn; })->thunk_p) &&
!__extension__ ({ struct lang_decl *lt = ((contains_struct_check
(((((enum tree_code) (thunk)->base.code) == TEMPLATE_DECL
? ((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((thunk), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4454, __FUNCTION__, (TEMPLATE_DECL))))))))->result : thunk
)), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4454, __FUNCTION__))->decl_common.lang_specific); if (!(
((enum tree_code) (thunk)->base.code) == FUNCTION_DECL || (
((enum tree_code) (thunk)->base.code) == TEMPLATE_DECL &&
((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((thunk), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4454, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((thunk
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4454, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)) || lt->u.base.selector != lds_fn
) lang_check_failed ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4454, __FUNCTION__); &lt->u.fn; })->this_thunk_p)
)
4455 {
4456 tree probe;
4457
4458 for (probe = DECL_THUNKS (thunk)(((contains_struct_check ((thunk), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4458, __FUNCTION__))->decl_common.virtual_flag) ? __extension__
({ struct lang_decl *lt = ((contains_struct_check (((((enum tree_code
) (thunk)->base.code) == TEMPLATE_DECL ? ((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((thunk
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4458, __FUNCTION__, (TEMPLATE_DECL))))))))->result : thunk
)), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4458, __FUNCTION__))->decl_common.lang_specific); if (!(
((enum tree_code) (thunk)->base.code) == FUNCTION_DECL || (
((enum tree_code) (thunk)->base.code) == TEMPLATE_DECL &&
((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((thunk), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4458, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((thunk
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4458, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)) || lt->u.base.selector != lds_fn
) lang_check_failed ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4458, __FUNCTION__); &lt->u.fn; })->context : (tree
) __null)
;
4459 probe; probe = DECL_CHAIN (probe)(((contains_struct_check (((contains_struct_check ((probe), (
TS_DECL_MINIMAL), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4459, __FUNCTION__))), (TS_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4459, __FUNCTION__))->common.chain))
)
4460 use_thunk (probe, /*emit_p=*/1);
4461 }
4462 }
4463 else
4464 gcc_assert (!DECL_THUNKS (thunk))((void)(!(!(((contains_struct_check ((thunk), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4464, __FUNCTION__))->decl_common.virtual_flag) ? __extension__
({ struct lang_decl *lt = ((contains_struct_check (((((enum tree_code
) (thunk)->base.code) == TEMPLATE_DECL ? ((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((thunk
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4464, __FUNCTION__, (TEMPLATE_DECL))))))))->result : thunk
)), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4464, __FUNCTION__))->decl_common.lang_specific); if (!(
((enum tree_code) (thunk)->base.code) == FUNCTION_DECL || (
((enum tree_code) (thunk)->base.code) == TEMPLATE_DECL &&
((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((thunk), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4464, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((thunk
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4464, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)) || lt->u.base.selector != lds_fn
) lang_check_failed ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4464, __FUNCTION__); &lt->u.fn; })->context : (tree
) __null)) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4464, __FUNCTION__), 0 : 0))
;
4465 }
4466 }
4467}
4468
4469/* Generate RTL for FN. */
4470
4471bool
4472expand_or_defer_fn_1 (tree fn)
4473{
4474 /* When the parser calls us after finishing the body of a template
4475 function, we don't really want to expand the body. */
4476 if (processing_template_declscope_chain->x_processing_template_decl)
4477 {
4478 /* Normally, collection only occurs in rest_of_compilation. So,
4479 if we don't collect here, we never collect junk generated
4480 during the processing of templates until we hit a
4481 non-template function. It's not safe to do this inside a
4482 nested class, though, as the parser may have local state that
4483 is not a GC root. */
4484 if (!function_depth)
4485 ggc_collect ();
4486 return false;
4487 }
4488
4489 gcc_assert (DECL_SAVED_TREE (fn))((void)(!(((tree_check ((fn), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4489, __FUNCTION__, (FUNCTION_DECL)))->function_decl.saved_tree
)) ? fancy_abort ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4489, __FUNCTION__), 0 : 0))
;
4490
4491 /* We make a decision about linkage for these functions at the end
4492 of the compilation. Until that point, we do not want the back
4493 end to output them -- but we do want it to see the bodies of
4494 these functions so that it can inline them as appropriate. */
4495 if (DECL_DECLARED_INLINE_P (fn)((tree_check ((fn), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4495, __FUNCTION__, (FUNCTION_DECL)))->function_decl.declared_inline_flag
)
|| DECL_IMPLICIT_INSTANTIATION (fn)((((contains_struct_check ((fn), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4495, __FUNCTION__))->decl_common.lang_specific)->u.base
.use_template) == 1)
)
4496 {
4497 if (DECL_INTERFACE_KNOWN (fn)((contains_struct_check ((fn), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4497, __FUNCTION__))->decl_common.lang_flag_5)
)
4498 /* We've already made a decision as to how this function will
4499 be handled. */;
4500 else if (!at_eof
4501 || DECL_IMMEDIATE_FUNCTION_P (fn)(((contains_struct_check (((tree_check (((((enum tree_code) (
fn)->base.code) == TEMPLATE_DECL ? ((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((fn),
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4501, __FUNCTION__, (TEMPLATE_DECL))))))))->result : fn)
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4501, __FUNCTION__, (FUNCTION_DECL)))), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4501, __FUNCTION__))->decl_common.lang_specific) ? __extension__
({ struct lang_decl *lt = ((contains_struct_check (((((enum tree_code
) (fn)->base.code) == TEMPLATE_DECL ? ((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((fn),
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4501, __FUNCTION__, (TEMPLATE_DECL))))))))->result : fn)
), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4501, __FUNCTION__))->decl_common.lang_specific); if (!(
((enum tree_code) (fn)->base.code) == FUNCTION_DECL || (((
enum tree_code) (fn)->base.code) == TEMPLATE_DECL &&
((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((fn), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4501, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((fn),
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4501, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)) || lt->u.base.selector != lds_fn
) lang_check_failed ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4501, __FUNCTION__); &lt->u.fn; })->immediate_fn_p
: false)
4502 || DECL_OMP_DECLARE_REDUCTION_P (fn)(__extension__ ({ struct lang_decl *lt = ((contains_struct_check
(((((enum tree_code) ((contains_struct_check ((fn), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4502, __FUNCTION__)))->base.code) == TEMPLATE_DECL ? ((struct
tree_template_decl *)(const_cast<union tree_node *> ((
((tree_check (((contains_struct_check ((fn), (TS_DECL_COMMON)
, "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4502, __FUNCTION__))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4502, __FUNCTION__, (TEMPLATE_DECL))))))))->result : (contains_struct_check
((fn), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4502, __FUNCTION__)))), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4502, __FUNCTION__))->decl_common.lang_specific); if (!(
((enum tree_code) ((contains_struct_check ((fn), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4502, __FUNCTION__)))->base.code) == FUNCTION_DECL || ((
(enum tree_code) ((contains_struct_check ((fn), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4502, __FUNCTION__)))->base.code) == TEMPLATE_DECL &&
((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check (((contains_struct_check ((fn), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4502, __FUNCTION__))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4502, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check (((contains_struct_check
((fn), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4502, __FUNCTION__))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4502, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)) || lt->u.base.selector != lds_fn
) lang_check_failed ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4502, __FUNCTION__); &lt->u.fn; })->omp_declare_reduction_p
)
)
4503 tentative_decl_linkage (fn);
4504 else
4505 import_export_decl (fn);
4506
4507 /* If the user wants us to keep all inline functions, then mark
4508 this function as needed so that finish_file will make sure to
4509 output it later. Similarly, all dllexport'd functions must
4510 be emitted; there may be callers in other DLLs. */
4511 if (DECL_DECLARED_INLINE_P (fn)((tree_check ((fn), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4511, __FUNCTION__, (FUNCTION_DECL)))->function_decl.declared_inline_flag
)
4512 && !DECL_REALLY_EXTERN (fn)(((contains_struct_check ((fn), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4512, __FUNCTION__))->decl_common.decl_flag_1) &&
(!((contains_struct_check ((fn), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4512, __FUNCTION__))->decl_common.lang_specific) || !(((
contains_struct_check ((fn), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4512, __FUNCTION__))->decl_common.lang_specific)->u.base
.not_really_extern)))
4513 && !DECL_IMMEDIATE_FUNCTION_P (fn)(((contains_struct_check (((tree_check (((((enum tree_code) (
fn)->base.code) == TEMPLATE_DECL ? ((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((fn),
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4513, __FUNCTION__, (TEMPLATE_DECL))))))))->result : fn)
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4513, __FUNCTION__, (FUNCTION_DECL)))), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4513, __FUNCTION__))->decl_common.lang_specific) ? __extension__
({ struct lang_decl *lt = ((contains_struct_check (((((enum tree_code
) (fn)->base.code) == TEMPLATE_DECL ? ((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((fn),
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4513, __FUNCTION__, (TEMPLATE_DECL))))))))->result : fn)
), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4513, __FUNCTION__))->decl_common.lang_specific); if (!(
((enum tree_code) (fn)->base.code) == FUNCTION_DECL || (((
enum tree_code) (fn)->base.code) == TEMPLATE_DECL &&
((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check ((fn), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4513, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((fn),
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4513, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)) || lt->u.base.selector != lds_fn
) lang_check_failed ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4513, __FUNCTION__); &lt->u.fn; })->immediate_fn_p
: false)
4514 && !DECL_OMP_DECLARE_REDUCTION_P (fn)(__extension__ ({ struct lang_decl *lt = ((contains_struct_check
(((((enum tree_code) ((contains_struct_check ((fn), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4514, __FUNCTION__)))->base.code) == TEMPLATE_DECL ? ((struct
tree_template_decl *)(const_cast<union tree_node *> ((
((tree_check (((contains_struct_check ((fn), (TS_DECL_COMMON)
, "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4514, __FUNCTION__))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4514, __FUNCTION__, (TEMPLATE_DECL))))))))->result : (contains_struct_check
((fn), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4514, __FUNCTION__)))), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4514, __FUNCTION__))->decl_common.lang_specific); if (!(
((enum tree_code) ((contains_struct_check ((fn), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4514, __FUNCTION__)))->base.code) == FUNCTION_DECL || ((
(enum tree_code) ((contains_struct_check ((fn), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4514, __FUNCTION__)))->base.code) == TEMPLATE_DECL &&
((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check (((contains_struct_check ((fn), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4514, __FUNCTION__))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4514, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check (((contains_struct_check
((fn), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4514, __FUNCTION__))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4514, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)) || lt->u.base.selector != lds_fn
) lang_check_failed ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4514, __FUNCTION__); &lt->u.fn; })->omp_declare_reduction_p
)
4515 && (flag_keep_inline_functionsglobal_options.x_flag_keep_inline_functions
4516 || (flag_keep_inline_dllexportglobal_options.x_flag_keep_inline_dllexport
4517 && lookup_attribute ("dllexport", DECL_ATTRIBUTES (fn)((contains_struct_check ((fn), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4517, __FUNCTION__))->decl_common.attributes)
))))
4518 {
4519 mark_needed (fn);
4520 DECL_EXTERNAL (fn)((contains_struct_check ((fn), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4520, __FUNCTION__))->decl_common.decl_flag_1)
= 0;
4521 }
4522 }
4523
4524 /* If this is a constructor or destructor body, we have to clone
4525 it. */
4526 if (maybe_clone_body (fn))
4527 {
4528 /* We don't want to process FN again, so pretend we've written
4529 it out, even though we haven't. */
4530 TREE_ASM_WRITTEN (fn)((fn)->base.asm_written_flag) = 1;
4531 /* If this is a constexpr function, keep DECL_SAVED_TREE. */
4532 if (!DECL_DECLARED_CONSTEXPR_P (fn)((contains_struct_check (((tree_check2 (((((enum tree_code) (
fn)->base.code) == TEMPLATE_DECL ? ((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check ((fn),
"/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4532, __FUNCTION__, (TEMPLATE_DECL))))))))->result : fn)
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4532, __FUNCTION__, (VAR_DECL), (FUNCTION_DECL)))), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4532, __FUNCTION__))->decl_common.lang_flag_8)
4533 && !(modules_p () && DECL_DECLARED_INLINE_P (fn)((tree_check ((fn), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4533, __FUNCTION__, (FUNCTION_DECL)))->function_decl.declared_inline_flag
)
))
4534 DECL_SAVED_TREE (fn)((tree_check ((fn), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4534, __FUNCTION__, (FUNCTION_DECL)))->function_decl.saved_tree
)
= NULL_TREE(tree) __null;
4535 return false;
4536 }
4537
4538 /* There's no reason to do any of the work here if we're only doing
4539 semantic analysis; this code just generates RTL. */
4540 if (flag_syntax_onlyglobal_options.x_flag_syntax_only)
4541 {
4542 /* Pretend that this function has been written out so that we don't try
4543 to expand it again. */
4544 TREE_ASM_WRITTEN (fn)((fn)->base.asm_written_flag) = 1;
4545 return false;
4546 }
4547
4548 if (DECL_OMP_DECLARE_REDUCTION_P (fn)(__extension__ ({ struct lang_decl *lt = ((contains_struct_check
(((((enum tree_code) ((contains_struct_check ((fn), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4548, __FUNCTION__)))->base.code) == TEMPLATE_DECL ? ((struct
tree_template_decl *)(const_cast<union tree_node *> ((
((tree_check (((contains_struct_check ((fn), (TS_DECL_COMMON)
, "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4548, __FUNCTION__))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4548, __FUNCTION__, (TEMPLATE_DECL))))))))->result : (contains_struct_check
((fn), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4548, __FUNCTION__)))), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4548, __FUNCTION__))->decl_common.lang_specific); if (!(
((enum tree_code) ((contains_struct_check ((fn), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4548, __FUNCTION__)))->base.code) == FUNCTION_DECL || ((
(enum tree_code) ((contains_struct_check ((fn), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4548, __FUNCTION__)))->base.code) == TEMPLATE_DECL &&
((struct tree_template_decl *)(const_cast<union tree_node
*> ((((tree_check (((contains_struct_check ((fn), (TS_DECL_COMMON
), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4548, __FUNCTION__))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4548, __FUNCTION__, (TEMPLATE_DECL))))))))->result != (tree
) __null && ((enum tree_code) (((struct tree_template_decl
*)(const_cast<union tree_node *> ((((tree_check (((contains_struct_check
((fn), (TS_DECL_COMMON), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4548, __FUNCTION__))), "/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4548, __FUNCTION__, (TEMPLATE_DECL))))))))->result)->
base.code) == FUNCTION_DECL)) || lt->u.base.selector != lds_fn
) lang_check_failed ("/home/marxin/BIG/buildbot/buildworker/marxinbox-gcc-clang-static-analyzer/build/gcc/cp/semantics.c"
, 4548, __FUNCTION__); &lt->u.fn; })->omp_declare_reduction_p
)
)
4549 return false;
4550
4551 return true;
4552}
4553
4554void
4555expand_or_defer_fn (tree fn)
4556{
4557 if (expand_or_defer_fn_1 (fn))
4558