Unverified Commit 7302b9b8 authored by Luca Boccassi's avatar Luca Boccassi Committed by GitHub

Merge pull request #3345 from ssbl/unused-import

Problem: unused import and inconsistent use of const
parents fc36c7d2 cc686f15
......@@ -33,7 +33,6 @@
#include "radix_tree.hpp"
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
node::node (unsigned char *data) : data_ (data)
......@@ -81,7 +80,7 @@ unsigned char *node::prefix ()
return data_ + 3 * sizeof (uint32_t);
}
void node::set_prefix (unsigned char const *bytes)
void node::set_prefix (const unsigned char *bytes)
{
memcpy (prefix (), bytes, prefix_length ());
}
......@@ -91,7 +90,7 @@ unsigned char *node::first_bytes ()
return prefix () + prefix_length ();
}
void node::set_first_bytes (unsigned char const *bytes)
void node::set_first_bytes (const unsigned char *bytes)
{
memcpy (first_bytes (), bytes, edgecount ());
}
......@@ -113,7 +112,7 @@ unsigned char *node::node_ptrs ()
return prefix () + prefix_length () + edgecount ();
}
void node::set_node_ptrs (unsigned char const *ptrs)
void node::set_node_ptrs (const unsigned char *ptrs)
{
memcpy (node_ptrs (), ptrs, edgecount () * sizeof (void *));
}
......
......@@ -83,7 +83,7 @@ struct node
inline void set_prefix (const unsigned char *prefix);
inline void set_first_bytes (const unsigned char *bytes);
inline void set_first_byte_at (size_t i, unsigned char byte);
inline void set_node_ptrs (unsigned char const *ptrs);
inline void set_node_ptrs (const unsigned char *ptrs);
inline void set_node_at (size_t i, node n);
inline void set_edge_at (size_t i, unsigned char byte, node n);
void resize (size_t prefix_length, size_t edgecount);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment