@@ -1538,14 +1538,9 @@ build_contract_condition_function (tree fndecl, bool pre)
1538
1538
*last = void_list_node;
1539
1539
1540
1540
/* The handlers are void fns. */
1541
- tree resdecl = build_decl (DECL_SOURCE_LOCATION (fndecl), RESULT_DECL,
1542
- 0 , void_type_node);
1543
- DECL_CONTEXT (resdecl) = fn;
1544
- DECL_ARTIFICIAL (resdecl) = true ;
1545
- DECL_IGNORED_P (resdecl) = true ;
1546
- DECL_RESULT (fn) = resdecl;
1547
-
1548
1541
TREE_TYPE (fn) = build_function_type (void_type_node, arg_types);
1542
+ DECL_RESULT (fn) = NULL_TREE; /* Let the start function code fill it in. */
1543
+
1549
1544
if (DECL_IOBJ_MEMBER_FUNCTION_P (fndecl))
1550
1545
TREE_TYPE (fn) = build_method_type (class_type, TREE_TYPE (fn));
1551
1546
@@ -1915,12 +1910,8 @@ build_contract_wrapper_function (tree fndecl, bool is_cvh,
1915
1910
/* This declaration is a contract wrapper function. */
1916
1911
DECL_CONTRACT_WRAPPER (wrapdecl) = true ;
1917
1912
1918
- /* Build our result decl. */
1919
- tree resdecl = build_decl (loc, RESULT_DECL, 0 , wrapper_return_type);
1920
- DECL_CONTEXT (resdecl) = wrapdecl;
1921
- DECL_ARTIFICIAL (resdecl) = true ;
1922
- DECL_IGNORED_P (resdecl) = true ;
1923
- DECL_RESULT (wrapdecl) = resdecl;
1913
+ /* Let the start function code fill in the result decl. */
1914
+ DECL_RESULT (wrapdecl) = NULL_TREE;
1924
1915
1925
1916
/* Copy the function parameters, if present. Suppress (e.g. unused)
1926
1917
warnings on them. */
0 commit comments