summaryrefslogtreecommitdiff
path: root/gs
diff options
context:
space:
mode:
authorL Peter Deutsch <lpd@ghostscript.com>2002-01-12 20:09:55 +0000
committerL Peter Deutsch <lpd@ghostscript.com>2002-01-12 20:09:55 +0000
commit1a027ae220ec83acc408a9f63a999bf53aff550e (patch)
tree1fb14ec17d16453f6c6c36ace787086fe27d9a5a /gs
parentaae400aa53a60a7a5e551f75da3bfb676f97ec38 (diff)
downloadghostpdl-1a027ae220ec83acc408a9f63a999bf53aff550e.tar.gz
Makes the cos_array_reorder procedure private (which it should have been
from the beginning). git-svn-id: http://svn.ghostscript.com/ghostscript/trunk@2018 a1074d23-0009-0410-80fe-cf8c14f379e6
Diffstat (limited to 'gs')
-rw-r--r--gs/src/gdevpdfo.c4
-rw-r--r--gs/src/gdevpdfo.h23
2 files changed, 16 insertions, 11 deletions
diff --git a/gs/src/gdevpdfo.c b/gs/src/gdevpdfo.c
index 9b01f55d7..ce901c389 100644
--- a/gs/src/gdevpdfo.c
+++ b/gs/src/gdevpdfo.c
@@ -465,6 +465,8 @@ cos_array_release(cos_object_t *pco, client_name_t cname)
pca->elements = 0;
}
+private cos_array_element_t *cos_array_reorder(const cos_array_t *pca,
+ cos_array_element_t *first);
private int
cos_array_write(const cos_object_t *pco, gx_device_pdf *pdev)
{
@@ -601,7 +603,7 @@ cos_array_element_next(const cos_array_element_t *pca, long *pindex,
* ...
* cos_array_reorder(pca, first_element);
*/
-cos_array_element_t *
+private cos_array_element_t *
cos_array_reorder(const cos_array_t *pca, cos_array_element_t *first)
{
cos_array_element_t *last;
diff --git a/gs/src/gdevpdfo.h b/gs/src/gdevpdfo.h
index 9c920336a..cdd4de572 100644
--- a/gs/src/gdevpdfo.h
+++ b/gs/src/gdevpdfo.h
@@ -248,22 +248,25 @@ int cos_stream_add_since(P2(cos_stream_t *, long /*start_pos*/));
int cos_stream_add_bytes(P3(cos_stream_t *, const byte *, uint));
cos_dict_t *cos_stream_dict(P1(cos_stream_t *));
-/* Get the first / next element for enumerating an array. */
+/*
+ * Get the first / next element for enumerating an array. Usage:
+ * const cos_array_element_t *elt = cos_array_element_first(pca);
+ * while (elt) {
+ * long idx;
+ * const cos_value_t *pvalue;
+ * elt = cos_array_element_next(elt, &idx, &pvalue);
+ * ...
+ * }
+ * The order in which the elements are returned is not defined.
+ * If the client adds elements to the array during the enumeration,
+ * they may or may not be included in the enumeration.
+ */
const cos_array_element_t *
cos_array_element_first(P1(const cos_array_t *));
const cos_array_element_t *
cos_array_element_next(P3(const cos_array_element_t *, long *,
const cos_value_t **));
-/*
- * Reorder the elements of an array for writing or after writing. Usage:
- * first_element = cos_array_reorder(pca, NULL);
- * ...
- * cos_array_reorder(pca, first_element);
- */
-cos_array_element_t *
- cos_array_reorder(P2(const cos_array_t *, cos_array_element_t *));
-
/* Look up a key in a dictionary. */
const cos_value_t *cos_dict_find(P3(const cos_dict_t *, const byte *, uint));
const cos_value_t *cos_dict_find_c_key(P2(const cos_dict_t *, const char *));