From: Jim Meyering <meyering@fb.com>
Date: Sat, 4 Jan 2014 01:17:27 +0000 (-0800)
Subject: freadable, fwritable, fwriting: declare with the "pure" attribute
X-Git-Tag: v1.0~7461
X-Git-Url: https://gitweb.git.savannah.gnu.org/gitweb/?a=commitdiff_plain;h=34af3d3fd03a60d19c3fde90bbb350d5567fec66;p=gnulib.git

freadable, fwritable, fwriting: declare with the "pure" attribute

* lib/freadable.h (freadable): Declare with the "pure" attribute.
* lib/fwritable.h (fwritable): Likewise.
* lib/fwriting.h (fwriting): Likewise.
Suggested by Bruno Haible.
---

diff --git a/ChangeLog b/ChangeLog
index a73c962a9e..278e656647 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,11 @@
 2014-01-03  Jim Meyering  <meyering@fb.com>
 
+	freadable, fwritable, fwriting: declare with the "pure" attribute
+	* lib/freadable.h (freadable): Declare with the "pure" attribute.
+	* lib/fwritable.h (fwritable): Likewise.
+	* lib/fwriting.h (fwriting): Likewise.
+	Suggested by Bruno Haible.
+
 	maint.mk: adapt openat.h-include-without-use test
 	* top/maint.mk (sc_prohibit_openat_without_use): Also check for
 	FCHMODAT_INLINE, FCHOWNAT_INLINE and STATAT_INLINE, to avoid
diff --git a/lib/freadable.h b/lib/freadable.h
index 0b8ad4213a..045555839f 100644
--- a/lib/freadable.h
+++ b/lib/freadable.h
@@ -33,7 +33,7 @@
 extern "C" {
 # endif
 
-extern bool freadable (FILE *stream);
+extern bool freadable (FILE *stream) _GL_ATTRIBUTE_PURE;
 
 # ifdef __cplusplus
 }
diff --git a/lib/fwritable.h b/lib/fwritable.h
index c42cb661af..6b7f0d2cb0 100644
--- a/lib/fwritable.h
+++ b/lib/fwritable.h
@@ -33,7 +33,7 @@
 extern "C" {
 # endif
 
-extern bool fwritable (FILE *stream);
+extern bool fwritable (FILE *stream) _GL_ATTRIBUTE_PURE;
 
 # ifdef __cplusplus
 }
diff --git a/lib/fwriting.h b/lib/fwriting.h
index c4a913a62e..b4a9b0dc60 100644
--- a/lib/fwriting.h
+++ b/lib/fwriting.h
@@ -44,7 +44,7 @@
 extern "C" {
 # endif
 
-extern bool fwriting (FILE *stream);
+extern bool fwriting (FILE *stream) _GL_ATTRIBUTE_PURE;
 
 # ifdef __cplusplus
 }