remove vc warnings

update-fork
MITSUNARI Shigeo 5 years ago
parent 2095a80e17
commit 42b0fb05ad
  1. 10
      include/mcl/ec.hpp
  2. 4
      include/mcl/mapto_wb19.hpp

@ -116,7 +116,7 @@ void mul1CT(G& Q, const G& P, const mpz_class& x)
}
}
}
mcl::FixedArray<int8_t, sizeof(F) * 8 / w + 1> vTbl[splitN];
mcl::FixedArray<uint8_t, sizeof(F) * 8 / w + 1> vTbl[splitN];
size_t bitSizeTbl[splitN];
size_t maxBitSize = 0;
for (size_t i = 0; i < splitN; i++) {
@ -126,18 +126,18 @@ void mul1CT(G& Q, const G& P, const mpz_class& x)
maxBitSize = bitSize;
}
}
int loopN = (maxBitSize + w - 1) / w;
size_t loopN = (maxBitSize + w - 1) / w;
for (int i = 0; i < splitN; i++) {
fp::ArrayIterator<fp::Unit> itr(gmp::getUnit(u[i]), bitSizeTbl[i], w);
bool b = vTbl[i].resize(loopN);
assert(b);
(void)b;
for (int j = 0; j < loopN; j++) {
vTbl[i][loopN - 1 - j] = itr.getNext();
for (size_t j = 0; j < loopN; j++) {
vTbl[i][loopN - 1 - j] = (uint8_t)itr.getNext();
}
}
Q.clear();
for (int k = 0; k < loopN; k++) {
for (size_t k = 0; k < loopN; k++) {
for (size_t i = 0; i < w; i++) {
G::dbl(Q, Q);
}

@ -81,9 +81,9 @@ struct MapToG2_WB19 {
Fp2 ynum[4];
Fp2 yden[4];
int draftVersion_;
void setDraftVersion(int version)
void setDraftVersion(int draftVersion)
{
draftVersion_ = version;
draftVersion_ = draftVersion;
}
void init()
{

Loading…
Cancel
Save