summaryrefslogtreecommitdiff
path: root/apt-pkg/contrib/hashsum_template.h
diff options
context:
space:
mode:
authorDavid Kalnischkies <kalnischkies@gmail.com>2011-09-19 13:31:29 +0200
committerDavid Kalnischkies <kalnischkies@gmail.com>2011-09-19 13:31:29 +0200
commit8f3ba4e8708cb72be19dacc2af4f601ee5fea292 (patch)
treef624675aa3d4add287f253e19eb28c0dce5669f1 /apt-pkg/contrib/hashsum_template.h
parentc333ea435b67d7d7d7d10e867298ecac4da0f7b8 (diff)
do not pollute namespace in the headers with using (Closes: #500198)
Diffstat (limited to 'apt-pkg/contrib/hashsum_template.h')
-rw-r--r--apt-pkg/contrib/hashsum_template.h13
1 files changed, 5 insertions, 8 deletions
diff --git a/apt-pkg/contrib/hashsum_template.h b/apt-pkg/contrib/hashsum_template.h
index 9157754e3..c109a8212 100644
--- a/apt-pkg/contrib/hashsum_template.h
+++ b/apt-pkg/contrib/hashsum_template.h
@@ -15,9 +15,6 @@
#include <algorithm>
#include <stdint.h>
-using std::string;
-using std::min;
-
template<int N>
class HashSumValue
{
@@ -31,7 +28,7 @@ class HashSumValue
return memcmp(Sum,rhs.Sum,sizeof(Sum)) == 0;
};
- string Value() const
+ std::string Value() const
{
char Conv[16] =
{ '0','1','2','3','4','5','6','7','8','9','a','b',
@@ -48,7 +45,7 @@ class HashSumValue
Result[I] = Conv[Sum[J] >> 4];
Result[I + 1] = Conv[Sum[J] & 0xF];
}
- return string(Result);
+ return std::string(Result);
};
inline void Value(unsigned char S[N/8])
@@ -57,12 +54,12 @@ class HashSumValue
S[I] = Sum[I];
};
- inline operator string() const
+ inline operator std::string() const
{
return Value();
};
- bool Set(string Str)
+ bool Set(std::string Str)
{
return Hex2Num(Str,Sum,sizeof(Sum));
};
@@ -73,7 +70,7 @@ class HashSumValue
Sum[I] = S[I];
};
- HashSumValue(string Str)
+ HashSumValue(std::string Str)
{
memset(Sum,0,sizeof(Sum));
Set(Str);