Skip to content

Commit

Permalink
Move one-line implementation of UniValue::read() to header.
Browse files Browse the repository at this point in the history
  • Loading branch information
jgarzik committed May 5, 2017
1 parent 52e85b3 commit d415300
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
3 changes: 2 additions & 1 deletion include/univalue.h
Expand Up @@ -7,6 +7,7 @@
#define __UNIVALUE_H__

#include <stdint.h>
#include <string.h>

#include <string>
#include <vector>
Expand Down Expand Up @@ -137,7 +138,7 @@ class UniValue {
unsigned int indentLevel = 0) const;

bool read(const char *raw, size_t len);
bool read(const char *raw);
bool read(const char *raw) { return read(raw, strlen(raw)); }
bool read(const std::string& rawStr) {
return read(rawStr.data(), rawStr.size());
}
Expand Down
3 changes: 0 additions & 3 deletions lib/univalue_read.cpp
Expand Up @@ -449,6 +449,3 @@ bool UniValue::read(const char *raw, size_t size)
return true;
}

bool UniValue::read(const char *raw) {
return read(raw, strlen(raw));
}

0 comments on commit d415300

Please sign in to comment.