public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc r14-1990] RISC-V: Fix compiler warning of riscv_arg_has_vector
@ 2023-06-20 13:05 Robin Dapp
0 siblings, 0 replies; only message in thread
From: Robin Dapp @ 2023-06-20 13:05 UTC (permalink / raw)
To: gcc-cvs
https://gcc.gnu.org/g:4a6c44f4ad4198382b7c70f4d40eefb69e71132e
commit r14-1990-g4a6c44f4ad4198382b7c70f4d40eefb69e71132e
Author: Lehua Ding <lehua.ding@rivai.ai>
Date: Tue Jun 20 17:45:17 2023 +0800
RISC-V: Fix compiler warning of riscv_arg_has_vector
Hi,
This little patch fixes a compile warning issue that my previous patch
introduced, sorry for introducing this issue.
Best,
Lehua
gcc/ChangeLog:
* config/riscv/riscv.cc (riscv_arg_has_vector): Add default
switch handler.
Diff:
---
gcc/config/riscv/riscv.cc | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/gcc/config/riscv/riscv.cc b/gcc/config/riscv/riscv.cc
index 6eb63a9d4de..9558e28de3f 100644
--- a/gcc/config/riscv/riscv.cc
+++ b/gcc/config/riscv/riscv.cc
@@ -3820,8 +3820,8 @@ riscv_arg_has_vector (const_tree type)
switch (TREE_CODE (type))
{
case RECORD_TYPE:
- /* If it is a record, it is further determined whether its fileds have
- vector type. */
+ /* If it is a record, it is further determined whether its fields have
+ vector type. */
for (tree f = TYPE_FIELDS (type); f; f = DECL_CHAIN (f))
if (TREE_CODE (f) == FIELD_DECL)
{
@@ -3835,6 +3835,8 @@ riscv_arg_has_vector (const_tree type)
break;
case ARRAY_TYPE:
return riscv_arg_has_vector (TREE_TYPE (type));
+ default:
+ break;
}
return false;
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2023-06-20 13:05 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-06-20 13:05 [gcc r14-1990] RISC-V: Fix compiler warning of riscv_arg_has_vector Robin Dapp
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).