https://gcc.gnu.org/g:cac993e84ea363dc593799ad1a6d0db5d0165f16
commit r15-1321-gcac993e84ea363dc593799ad1a6d0db5d0165f16 Author: Marc Poulhiès <poulh...@adacore.com> Date: Thu Feb 29 10:51:40 2024 +0100 ada: Typo and indentation fix Fixes typo in comments and 2 instances of bad indentation. gcc/ada/ * gcc-interface/decl.cc (gnat_to_gnu_entity): Typo fix. (gnat_to_gnu_component_type): Indent fix. * gcc-interface/gigi.h (build_call_alloc_dealloc): Typo fix. * gcc-interface/utils.cc (make_dummy_type): Typo fix. * gcc-interface/utils2.cc (gnat_protect_expr): Indent fix. Diff: --- gcc/ada/gcc-interface/decl.cc | 8 ++++---- gcc/ada/gcc-interface/gigi.h | 2 +- gcc/ada/gcc-interface/utils.cc | 2 +- gcc/ada/gcc-interface/utils2.cc | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/gcc/ada/gcc-interface/decl.cc b/gcc/ada/gcc-interface/decl.cc index 8b72c96c4396..239837426059 100644 --- a/gcc/ada/gcc-interface/decl.cc +++ b/gcc/ada/gcc-interface/decl.cc @@ -1384,7 +1384,7 @@ gnat_to_gnu_entity (Entity_Id gnat_entity, tree gnu_expr, bool definition) volatile_flag = false; gnu_size = NULL_TREE; - /* In case this was a aliased object whose nominal subtype is + /* In case this was an aliased object whose nominal subtype is unconstrained, the pointer above will be a thin pointer and build_allocator will automatically make the template. @@ -2103,7 +2103,7 @@ gnat_to_gnu_entity (Entity_Id gnat_entity, tree gnu_expr, bool definition) 1. the array type (suffix XUA) containing the actual data, - 2. the template type (suffix XUB) containng the bounds, + 2. the template type (suffix XUB) containing the bounds, 3. the fat pointer type (suffix XUP) representing a pointer or a reference to the unconstrained array type: @@ -5445,8 +5445,8 @@ gnat_to_gnu_component_type (Entity_Id gnat_array, bool definition, if (gnu_comp_align > TYPE_ALIGN (gnu_type)) gnu_comp_align = 0; } - else - gnu_comp_align = 0; + else + gnu_comp_align = 0; gnu_type = maybe_pad_type (gnu_type, gnu_comp_size, gnu_comp_align, gnat_array, true, definition, true); diff --git a/gcc/ada/gcc-interface/gigi.h b/gcc/ada/gcc-interface/gigi.h index f3205a8a25d9..6ed74d6879ee 100644 --- a/gcc/ada/gcc-interface/gigi.h +++ b/gcc/ada/gcc-interface/gigi.h @@ -906,7 +906,7 @@ extern tree build_call_alloc_dealloc (tree gnu_obj, tree gnu_size, Entity_Id gnat_pool, Node_Id gnat_node); /* Build a GCC tree to correspond to allocating an object of TYPE whose - initial value if INIT, if INIT is nonzero. Convert the expression to + initial value is INIT, if INIT is nonzero. Convert the expression to RESULT_TYPE, which must be some type of pointer. Return the tree. GNAT_PROC and GNAT_POOL optionally give the procedure to call and diff --git a/gcc/ada/gcc-interface/utils.cc b/gcc/ada/gcc-interface/utils.cc index ae520542ace6..771cb1a17cad 100644 --- a/gcc/ada/gcc-interface/utils.cc +++ b/gcc/ada/gcc-interface/utils.cc @@ -499,7 +499,7 @@ make_dummy_type (Entity_Id gnat_type) if (No (gnat_equiv)) gnat_equiv = gnat_type; - /* If it there already a dummy type, use that one. Else make one. */ + /* If there is already a dummy type, use that one. Else make one. */ if (PRESENT_DUMMY_NODE (gnat_equiv)) return GET_DUMMY_NODE (gnat_equiv); diff --git a/gcc/ada/gcc-interface/utils2.cc b/gcc/ada/gcc-interface/utils2.cc index 4b7e2739f6a2..70271cf28365 100644 --- a/gcc/ada/gcc-interface/utils2.cc +++ b/gcc/ada/gcc-interface/utils2.cc @@ -2884,7 +2884,7 @@ gnat_protect_expr (tree exp) if (code == NON_LVALUE_EXPR || CONVERT_EXPR_CODE_P (code) || code == VIEW_CONVERT_EXPR) - return build1 (code, type, gnat_protect_expr (TREE_OPERAND (exp, 0))); + return build1 (code, type, gnat_protect_expr (TREE_OPERAND (exp, 0))); /* If we're indirectly referencing something, we only need to protect the address since the data itself can't change in these situations. */