8000 Remove unused stuff: GLOBAL_TIMEZONE and matchInteger. · thurt/arangodb@b4887dc · GitHub
[go: up one dir, main page]

Skip to content

Commit b4887dc

Browse files
committed
Remove unused stuff: GLOBAL_TIMEZONE and matchInteger.
1 parent 8d74f10 commit b4887dc

File tree

2 files changed

+0
-57
lines changed

2 files changed

+0
-57
lines changed

lib/Basics/StringUtils.cpp

Lines changed: 0 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -39,15 +39,6 @@
3939
#include "Basics/Exceptions.h"
4040
#include "Basics/StringBuffer.h"
4141

42-
// TODO need to this in another way
43-
#ifndef TRI_HAVE_GLOBAL_TIMEZONE_PROTO
44-
#ifdef GLOBAL_TIMEZONE
45-
extern long GLOBAL_TIMEZONE;
46-
#else
47-
static long GLOBAL_TIMEZONE = 0;
48-
#endif
49-
#endif
50-
5142
using namespace std;
5243

5344
// -----------------------------------------------------------------------------
@@ -59,57 +50,16 @@ namespace {
5950
return a == ' ' || a == '\t' || a == '_';
6051
}
6152

62-
63-
64-
int32_t matchInteger (char const * & str, size_t size) {
65-
int32_t result = 0;
66-
67-
for (size_t i = 0; i < size; i++, str++) {
68-
if ('0' <= *str && *str <= '9') {
69-
result = result * 10 + (*str - '0');
70-
}
71-
else {
72-
std::string message("cannot parse date, expecting integer, got '" + string(1, *str) + "'");
73-
THROW_ARANGO_EXCEPTION_MESSAGE(TRI_ERROR_BAD_PARAMETER, message);
74-
}
75-
}
76-
77-
return result;
78-
}
79-
80-
81-
82-
int32_t matchInteger (char const * & str) {
83-
int32_t result = 0;
84-
85-
for (; *str; str++) {
86-
if ('0' <= *str && *str <= '9') {
87-
result = result * 10 + (*str - '0');
88-
}
89-
else {
90-
return result;
91-
}
92-
}
93-
94-
return result;
95-
}
96-
97-
98-
9953
char const * const BASE64_CHARS =
10054
"ABCDEFGHIJKLMNOPQRSTUVWXYZ"
10155
"abcdefghijklmnopqrstuvwxyz"
10256
"0123456789+/";
10357

104-
105-
10658
char const * const BASE64U_CHARS =
10759
"ABCDEFGHIJKLMNOPQRSTUVWXYZ"
10860
"abcdefghijklmnopqrstuvwxyz"
10961
"0123456789-_";
11062

111-
112-
11363
unsigned char const BASE64_REVS[256] = {
11464
'\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0', // 0
11565
'\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0', // 16

lib/Basics/operating-system.h

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -116,8 +116,6 @@
116116
/// @brief available features
117117
////////////////////////////////////////////////////////////////////////////////
118118

119-
#define GLOBAL_TIMEZONE timezone
120-
121119
#define TRI_HAVE_POSIX 1
122120

123121
#define TRI_HAVE_MACOS_MEM_STATS 1
@@ -463,8 +461,6 @@
463461
/// @brief available features
464462
////////////////////////////////////////////////////////////////////////////////
465463

466-
#define GLOBAL_TIMEZONE timezone
467-
468464
#define TRI_GCC_THREAD_LOCAL_STORAGE 1
469465

470466
#define TRI_HAVE_POSIX 1
@@ -646,9 +642,6 @@
646642

647643
#define TRI_HAVE_LINENOISE 1
648644

649-
#define GLOBAL_TIMEZONE _timezone
650-
#define TRI_HAVE_GLOBAL_TIMEZONE_PROTO 1
651-
652645
#define YY_NO_UNISTD_H 1
653646

654647
#define TRI_WIN32_CONSOLE 1

0 commit comments

Comments
 (0)
0