|
From: <sv...@va...> - 2009-02-23 19:12:08
|
Author: bart
Date: 2009-02-23 19:12:02 +0000 (Mon, 23 Feb 2009)
New Revision: 9245
Log:
Declared those function arguments that are not modified as const.
Modified:
trunk/coregrind/m_oset.c
trunk/include/pub_tool_oset.h
Modified: trunk/coregrind/m_oset.c
===================================================================
--- trunk/coregrind/m_oset.c 2009-02-23 17:18:58 UTC (rev 9244)
+++ trunk/coregrind/m_oset.c 2009-02-23 19:12:02 UTC (rev 9245)
@@ -174,7 +174,7 @@
}
// Compare the first word of each element. Inlining is *crucial*.
-static inline Word fast_cmp(void* k, AvlNode* n)
+static inline Word fast_cmp(const void* k, const AvlNode* n)
{
UWord w1 = *(UWord*)k;
UWord w2 = *(UWord*)elem_of_node(n);
@@ -785,7 +785,7 @@
// produced VG_(OSetGen_Next) is the smallest key in the map
// >= start_at. Naturally ">=" is defined by the comparison
// function supplied to VG_(OSetGen_Create).
-void VG_(OSetGen_ResetIterAt)(AvlTree* oset, void* k)
+void VG_(OSetGen_ResetIterAt)(AvlTree* oset, const void* k)
{
Int i;
AvlNode *n, *t;
Modified: trunk/include/pub_tool_oset.h
===================================================================
--- trunk/include/pub_tool_oset.h 2009-02-23 17:18:58 UTC (rev 9244)
+++ trunk/include/pub_tool_oset.h 2009-02-23 19:12:02 UTC (rev 9245)
@@ -250,7 +250,7 @@
// produced VG_(OSetGen_Next) is the smallest key in the map
// >= start_at. Naturally ">=" is defined by the comparison
// function supplied to VG_(OSetGen_Create).
-extern void VG_(OSetGen_ResetIterAt) ( OSet* oset, void* key );
+extern void VG_(OSetGen_ResetIterAt) ( OSet* oset, const void* key );
#endif // __PUB_TOOL_OSET_H
|