]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
maint: make-prime-list: avoid -Wsuggest-attribute=const warning
authorJim Meyering <meyering@redhat.com>
Wed, 19 Sep 2012 09:07:41 +0000 (11:07 +0200)
committerJim Meyering <meyering@redhat.com>
Thu, 4 Oct 2012 19:33:05 +0000 (21:33 +0200)
* src/make-prime-list.c: Include <config.h>.
(binvert): Add _GL_ATTRIBUTE_CONST.

src/make-prime-list.c

index 1f5b3ce11fc68438d08469270eccf2aa2f544c54..724924b40ce7e1a89ca95b192917cb8545759631 100644 (file)
@@ -17,6 +17,8 @@ PARTICULAR PURPOSE.  See the GNU General Public License for more details.
 You should have received a copy of the GNU General Public License along with
 this program.  If not, see http://www.gnu.org/licenses/.  */
 
+#include <config.h>
+
 #include <stdint.h>
 #include <stdio.h>
 #include <string.h>
@@ -29,7 +31,7 @@ struct prime
   uintmax_t lim; /* floor(UINTMAX_MAX / p) */
 };
 
-static uintmax_t
+static uintmax_t _GL_ATTRIBUTE_CONST
 binvert (uintmax_t a)
 {
   uintmax_t x = 0xf5397db1 >> (4*((a/2) & 0x7));