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.129.124]) by sourceware.org (Postfix) with ESMTPS id 57434385696E for ; Fri, 21 Oct 2022 08:43:55 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 57434385696E Received: from mail-wm1-f70.google.com (mail-wm1-f70.google.com [209.85.128.70]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_128_GCM_SHA256) id us-mta-665-lDsqaw1cNSGpViT13HIE2A-1; Fri, 21 Oct 2022 04:43:53 -0400 X-MC-Unique: lDsqaw1cNSGpViT13HIE2A-1 Received: by mail-wm1-f70.google.com with SMTP id n6-20020a7bc5c6000000b003c6bbe5d5cfso3031539wmk.4 for ; Fri, 21 Oct 2022 01:43:53 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=5v1Bhb64nucL2yCOm9su8EAO59hy8Nl1DJEh1tqyVnI=; b=2d07d850PFjrMrepw/DCIuInSA25+bxCPApo+zNYot0dScoinTnX7+N35UE5LPHMiN 3Aj2a56z1Od7CmSpk7j9M5+ShFhQBBGKRaIsEMHX2ZV9CBxWdLlEtCbRUllobsooIW8Q lrhcpruasYCrbNRytH53YJwul9hbVfdgVv/7Z+tKDX1gYKuhBhCftU9Enb9pP/tm+xQW xVLUAcMuxXFzFjofYNPKIFmPrZc6uwvjrAq9mQE7A0RbG/gsMSA2grhcRUpLHzkR0wPC 8SLMGk3/jBuQqNYQuoPdbjiBHyLkLRX2tuu4vIQEMiMZQxkySZIyzIJiwjKe7VVaHb0O gVxg== X-Gm-Message-State: ACrzQf3g6Qcu+dqo3m+NKSMnnTsRYCg6jAHfsLbmVcpup2XUtyAg0dFc Pl/Zu2aSyLD2btlDNHAFcv40WMlZv4nNMOQWznvcNJQ4hOCG+Q+IXPaLLpwCqFghDi2RJ7K1xBv tfT+x+4YM5yY3WoceLv2fYhXD9pro4ipJpLLDpisSPoKwOWYJyp58lESiFqg+OTuBd+jPssS1hA == X-Received: by 2002:a05:600c:46ce:b0:3c6:f243:8d74 with SMTP id q14-20020a05600c46ce00b003c6f2438d74mr20834520wmo.166.1666341832410; Fri, 21 Oct 2022 01:43:52 -0700 (PDT) X-Google-Smtp-Source: AMsMyM4Y61WMAxYcGwQxAmUzp1hS1ivUG3ZQdh5mfbMkr4XmN21oaw2SnfT0V+fgX9btOkhz6YDI8Q== X-Received: by 2002:a05:600c:46ce:b0:3c6:f243:8d74 with SMTP id q14-20020a05600c46ce00b003c6f2438d74mr20834498wmo.166.1666341832091; Fri, 21 Oct 2022 01:43:52 -0700 (PDT) Received: from localhost ([31.111.84.238]) by smtp.gmail.com with ESMTPSA id n4-20020a1ca404000000b003a601a1c2f7sm2035732wme.19.2022.10.21.01.43.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 21 Oct 2022 01:43:51 -0700 (PDT) From: Andrew Burgess To: gdb-patches@sourceware.org Subject: [PATCH 01/12] gdb: int to bool conversion for normal_stop Date: Fri, 21 Oct 2022 09:43:37 +0100 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-default=true X-Spam-Status: No, score=-11.9 required=5.0 tests=BAYES_00, DKIM_INVALID, DKIM_SIGNED, GIT_PATCH_0, KAM_DMARC_NONE, KAM_DMARC_STATUS, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Oct 2022 08:43:58 -0000 Change the return type of normal_stop (infrun.c) from int to bool. Update callers. There should be no user visible changes after this commit. --- gdb/infcmd.c | 2 +- gdb/infrun.c | 6 +++--- gdb/infrun.h | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/gdb/infcmd.c b/gdb/infcmd.c index d729732c81c..6af11ac0cb6 100644 --- a/gdb/infcmd.c +++ b/gdb/infcmd.c @@ -873,7 +873,7 @@ step_1 (int skip_subroutines, int single_inst, const char *count_string) proceed ((CORE_ADDR) -1, GDB_SIGNAL_DEFAULT); else { - int proceeded; + bool proceeded; /* Stepped into an inline frame. Pretend that we've stopped. */ diff --git a/gdb/infrun.c b/gdb/infrun.c index cdfe02393f5..39840ef32c8 100644 --- a/gdb/infrun.c +++ b/gdb/infrun.c @@ -8614,7 +8614,7 @@ stop_context::changed () const /* See infrun.h. */ -int +bool normal_stop (void) { struct target_waitstatus last; @@ -8774,7 +8774,7 @@ normal_stop (void) the observers would print a stop for the wrong thread/inferior. */ if (saved_context.changed ()) - return 1; + return true; /* Notify observers about the stop. This is where the interpreters print the stop event. */ @@ -8796,7 +8796,7 @@ normal_stop (void) breakpoint_auto_delete (inferior_thread ()->control.stop_bpstat); } - return 0; + return false; } int diff --git a/gdb/infrun.h b/gdb/infrun.h index c711b9b21cc..11a18583e68 100644 --- a/gdb/infrun.h +++ b/gdb/infrun.h @@ -149,7 +149,7 @@ extern process_stratum_target *user_visible_resume_target (ptid_t resume_ptid); appropriate messages, remove breakpoints, give terminal our modes, and run the stop hook. Returns true if the stop hook proceeded the target, false otherwise. */ -extern int normal_stop (void); +extern bool normal_stop (void); /* Return the cached copy of the last target/ptid/waitstatus returned by target_wait(). The data is actually cached by handle_inferior_event(), -- 2.25.4