From 73658e70d9edfab77d7a50039b3ab7d2be3a41a0 Mon Sep 17 00:00:00 2001 From: Richard Biener Date: Wed, 3 Nov 2021 09:57:21 +0100 Subject: Make sbitmap bitmap_set_bit and bitmap_clear_bit return changed state The following adjusts the sbitmap bitmap_set_bit and bitmap_clear_bit APIs to match that of bitmap by returning a bool indicating whether the bitmap was changed. I've also changed bitmap_bit_p to return a bool rather than an int and made use of the sbitmap bitmap_set_bit API change in one place. 2021-11-03 Richard Biener * bitmap.h (bitmap_bit_p): Change the return type to bool. * bitmap.c (bitmap_bit_p): Likewise. * sbitmap.h (bitmap_bit_p): Likewise. (bitmap_set_bit): Return whether the bit changed. (bitmap_clear_bit): Likewise. * tree-ssa.c (verify_vssa): Make use of the changed state from bitmap_set_bit. --- gcc/bitmap.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gcc/bitmap.h') diff --git a/gcc/bitmap.h b/gcc/bitmap.h index 1bddcdb..fc33877 100644 --- a/gcc/bitmap.h +++ b/gcc/bitmap.h @@ -436,7 +436,7 @@ extern bool bitmap_clear_bit (bitmap, int); extern bool bitmap_set_bit (bitmap, int); /* Return true if a bit is set in a bitmap. */ -extern int bitmap_bit_p (const_bitmap, int); +extern bool bitmap_bit_p (const_bitmap, int); /* Set and get multiple bit values in a sparse bitmap. This allows a bitmap to function as a sparse array of bit patterns where the patterns are -- cgit v1.1 From 7adcbafe45f8001b698967defe682687b52c0007 Mon Sep 17 00:00:00 2001 From: Jakub Jelinek Date: Mon, 3 Jan 2022 10:42:10 +0100 Subject: Update copyright years. --- gcc/bitmap.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gcc/bitmap.h') diff --git a/gcc/bitmap.h b/gcc/bitmap.h index fc33877..7fba443 100644 --- a/gcc/bitmap.h +++ b/gcc/bitmap.h @@ -1,5 +1,5 @@ /* Functions to support general ended bitmaps. - Copyright (C) 1997-2021 Free Software Foundation, Inc. + Copyright (C) 1997-2022 Free Software Foundation, Inc. This file is part of GCC. -- cgit v1.1