From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTPS id 982D83858414 for ; Fri, 25 Feb 2022 11:31:20 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 982D83858414 Received: from mail-wm1-f72.google.com (mail-wm1-f72.google.com [209.85.128.72]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-638-7F92RlrIMzqs6u3WNnfd9w-1; Fri, 25 Feb 2022 06:31:19 -0500 X-MC-Unique: 7F92RlrIMzqs6u3WNnfd9w-1 Received: by mail-wm1-f72.google.com with SMTP id ay7-20020a05600c1e0700b003813d7a7d03so395016wmb.1 for ; Fri, 25 Feb 2022 03:31:18 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=96qIVdZyy8OCo5vUL5jnD8iaDp1scdmv9mpOUPUCHeQ=; b=Ya47In7vnQBbfTzrPqdxw1pspzZCksUvV9/GOtdu/Yiy0HxmPTUoBxw5yFkdEOGa6F qilxc+Qhgz5K7kANYONqgztmNh3AcNKe+h+GThT0AaJZcxZQeFbyAekWzpPOVahrbBSE E/2o2rlTODEM8CNuql7z2it8ViyBefO/54KQUcfBKdxsBDJK9EJNvhUN7JKczZKdtUaR Rt5lcJzGKLH7FBnDq1kD7coqC6UGxcbmGcg0gunm2EACUEcM9k0R9aCBQM2kxzUFWjXX TSwX+BjqKrC6feH/5PUmR/RDYJbAPQPVOWZeiOQkBkFt+/YNdRK9rzH2iB4BWZnjjKpL kU4g== X-Gm-Message-State: AOAM53206KQebfrK5KetzEitgLZFvGjHXVewNndsirzcM8y20J+fQRVw C0G5Zy1y9UBE+pS7olAweUiBP3bh0NJbbU5aalY+KSooXeaFlzD8zpT4A0C7f/KjLfy+FvCPhJU efxNuZaA0Ee/leQ3/ybOM9aDhjOT+ngx7HCBNoh6DkEJmMjQeSAwiqHd2TJWhR9bWkVVO2g== X-Received: by 2002:adf:f1ca:0:b0:1ed:e2d7:b5f3 with SMTP id z10-20020adff1ca000000b001ede2d7b5f3mr5929520wro.75.1645788677755; Fri, 25 Feb 2022 03:31:17 -0800 (PST) X-Google-Smtp-Source: ABdhPJxLg6sqa2OLAW0FYXdIFJdriIZx15iCXaLfYevMWbqPDGAhbqD/iBh9CtHJWvo7fLttf2HfUg== X-Received: by 2002:adf:f1ca:0:b0:1ed:e2d7:b5f3 with SMTP id z10-20020adff1ca000000b001ede2d7b5f3mr5929509wro.75.1645788677526; Fri, 25 Feb 2022 03:31:17 -0800 (PST) Received: from localhost (host86-169-131-29.range86-169.btcentralplus.com. [86.169.131.29]) by smtp.gmail.com with ESMTPSA id a11-20020adffb8b000000b001e4b2617e5asm1996108wrr.29.2022.02.25.03.31.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Feb 2022 03:31:17 -0800 (PST) From: Andrew Burgess To: binutils@sourceware.org Cc: Andrew Burgess Subject: [PATCHv3 0/3] Add Type.is_scalar and Type.is_signed properties Date: Fri, 25 Feb 2022 11:31:09 +0000 Message-Id: X-Mailer: git-send-email 2.25.4 In-Reply-To: References: MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII" X-Spam-Status: No, score=-5.8 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H5, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_NONE, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: binutils@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Binutils mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Feb 2022 11:31:22 -0000 Thanks for all the feedback on V1, and V2. Additionally, Simon gave some awesome suggestions on IRC The new V3 series is a complete rewrite, main points are: - New Type.is_scalar property in patch #1, - Now have a Type.is_signed property (patch #2), which is either True or False. Attempting to read this property on a non-scalar type will raise a ValueError. - Finally, patch #3 adds a test for to cover the 'char' is different to 'signed char' and 'unsigned char' issue. This characteristic should be detected by simply comparing types. Thoughts? Thanks, Andrew --- Andrew Burgess (3): gdb/python: add Type.is_scalar property gdb/python: add Type.is_signed property gdb/testsuite: add new test for comparing char types in Python gdb/NEWS | 8 +++ gdb/doc/python.texi | 16 +++++ gdb/python/py-type.c | 38 ++++++++++++ gdb/testsuite/gdb.python/py-arch.exp | 15 ++++- gdb/testsuite/gdb.python/py-type.c | 16 +++++ gdb/testsuite/gdb.python/py-type.exp | 88 +++++++++++++++++++++++++++- 6 files changed, 179 insertions(+), 2 deletions(-) -- 2.25.4