poke-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] bugfixes on pvm-val.c


From: Jose E. Marchesi
Subject: Re: [PATCH] bugfixes on pvm-val.c
Date: Fri, 07 Aug 2020 19:20:07 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

Hi Kostas.

This is OK for master.
Thanks!

> Hello! These are some minor fixes on pvm-val.c.
>
> From: kostasch <sdi1600195@di.uoa.gr>
> Date: Fri, 7 Aug 2020 20:08:15 +0300
> Subject: [PATCH] bugfixes on pvm-val.c
>
> 2020-08-07  Kostas Chasialis  <sdi1600195@di.uoa.gr>
>
>       * libpoke/pvm-val.c (pvm_type_equal): Bugfixes.
> ---
>  ChangeLog         |  4 ++++
>  libpoke/pvm-val.c | 10 ++--------
>  2 files changed, 6 insertions(+), 8 deletions(-)
>
> diff --git a/ChangeLog b/ChangeLog
> index a8763603..f1be4915 100644
> --- a/ChangeLog
> +++ b/ChangeLog
> @@ -1,3 +1,7 @@
> +2020-08-07  Kostas Chasialis  <sdi1600195@di.uoa.gr>
> +
> +     * libpoke/pvm-val.c (pvm_type_equal): Bugfixes.
> +
>  2020-08-04  Jose E. Marchesi  <jemarch@gnu.org>
>  
>       * libpoke/libpoke.h: Document that PK_NULL should have the same
> diff --git a/libpoke/pvm-val.c b/libpoke/pvm-val.c
> index c9cbcbf9..2042cfa8 100644
> --- a/libpoke/pvm-val.c
> +++ b/libpoke/pvm-val.c
> @@ -1103,30 +1103,25 @@ pvm_type_equal (pvm_val type1, pvm_val type2)
>        {
>          size_t t1_size = PVM_VAL_ULONG (PVM_VAL_TYP_I_SIZE (type1));
>          size_t t2_size = PVM_VAL_ULONG (PVM_VAL_TYP_I_SIZE (type2));
> -        uint32_t t1_signed = PVM_VAL_INT (PVM_VAL_TYP_I_SIGNED_P (type1));
> -        uint32_t t2_signed = PVM_VAL_INT (PVM_VAL_TYP_I_SIGNED_P (type2));
> +        int32_t t1_signed = PVM_VAL_INT (PVM_VAL_TYP_I_SIGNED_P (type1));
> +        int32_t t2_signed = PVM_VAL_INT (PVM_VAL_TYP_I_SIGNED_P (type2));
>  
>          return (t1_size == t2_size && t1_signed == t2_signed);
> -        break;
>        }
>      case PVM_TYPE_STRING:
>      case PVM_TYPE_ANY:
>        return 1;
> -      break;
>      case PVM_TYPE_ARRAY:
>        return pvm_type_equal (PVM_VAL_TYP_A_ETYPE (type1),
>                               PVM_VAL_TYP_A_ETYPE (type2));
> -      break;
>      case PVM_TYPE_STRUCT:
>        return (STREQ (PVM_VAL_STR (PVM_VAL_TYP_S_NAME (type1)),
>                       PVM_VAL_STR (PVM_VAL_TYP_S_NAME (type2))));
> -      break;
>      case PVM_TYPE_OFFSET:
>        return (pvm_type_equal (PVM_VAL_TYP_O_BASE_TYPE (type1),
>                                PVM_VAL_TYP_O_BASE_TYPE (type2))
>                && (PVM_VAL_ULONG (PVM_VAL_TYP_O_UNIT (type1))
>                    == PVM_VAL_ULONG (PVM_VAL_TYP_O_UNIT (type2))));
> -      break;
>      case PVM_TYPE_CLOSURE:
>        {
>          size_t i, nargs;
> @@ -1149,7 +1144,6 @@ pvm_type_equal (pvm_val type1, pvm_val type2)
>  
>          return 1;
>        }
> -      break;
>      default:
>        assert (0);
>      }



reply via email to

[Prev in Thread] Current Thread [Next in Thread]