diff options
author | MITSUNARI Shigeo <herumi@nifty.com> | 2018-05-28 12:42:47 +0800 |
---|---|---|
committer | MITSUNARI Shigeo <herumi@nifty.com> | 2018-05-29 04:55:10 +0800 |
commit | 4914d4ce293508c0224c0f62eb1c0efad492f75a (patch) | |
tree | 6669f2f5cc84675280fae72de9422b0106482d53 | |
parent | 4030fb3e0558ab3cf463be31e6a717d9a0e8996d (diff) | |
download | dexon-mcl-4914d4ce293508c0224c0f62eb1c0efad492f75a.tar.gz dexon-mcl-4914d4ce293508c0224c0f62eb1c0efad492f75a.tar.zst dexon-mcl-4914d4ce293508c0224c0f62eb1c0efad492f75a.zip |
remove bn_current
-rw-r--r-- | include/mcl/she.hpp | 17 | ||||
-rw-r--r-- | src/she_c_impl.hpp | 2 | ||||
-rw-r--r-- | test/she_test.cpp | 2 |
3 files changed, 6 insertions, 15 deletions
diff --git a/include/mcl/she.hpp b/include/mcl/she.hpp index e97059b..0eee669 100644 --- a/include/mcl/she.hpp +++ b/include/mcl/she.hpp @@ -15,19 +15,10 @@ #endif #if MCLBN_FP_UNIT_SIZE == 4 #include <mcl/bn256.hpp> -namespace mcl { -namespace bn_current = mcl::bn256; -} #elif MCLBN_FP_UNIT_SIZE == 6 #include <mcl/bn384.hpp> -namespace mcl { -namespace bn_current = mcl::bn384; -} #elif MCLBN_FP_UNIT_SIZE == 8 #include <mcl/bn512.hpp> -namespace mcl { -namespace bn_current = mcl::bn512; -} #else #error "MCLBN_FP_UNIT_SIZE must be 4, 6, or 8" #endif @@ -38,7 +29,7 @@ namespace bn_current = mcl::bn512; namespace mcl { namespace she { -using namespace mcl::bn_current; +using namespace mcl::bn; namespace local { @@ -106,9 +97,9 @@ struct InterfaceForHashTable<G, false> : G { template<class G> char GtoChar(); -template<>char GtoChar<bn_current::G1>() { return '1'; } -template<>char GtoChar<bn_current::G2>() { return '2'; } -template<>char GtoChar<bn_current::GT>() { return 'T'; } +template<>char GtoChar<bn::G1>() { return '1'; } +template<>char GtoChar<bn::G2>() { return '2'; } +template<>char GtoChar<bn::GT>() { return 'T'; } /* HashTable<EC, true> or HashTable<Fp12, false> diff --git a/src/she_c_impl.hpp b/src/she_c_impl.hpp index 25054b8..58afe2a 100644 --- a/src/she_c_impl.hpp +++ b/src/she_c_impl.hpp @@ -12,7 +12,7 @@ #include <mcl/she.hpp> using namespace mcl::she; -using namespace mcl::bn_current; +using namespace mcl::bn; static SecretKey *cast(sheSecretKey *p) { return reinterpret_cast<SecretKey*>(p); } static const SecretKey *cast(const sheSecretKey *p) { return reinterpret_cast<const SecretKey*>(p); } diff --git a/test/she_test.cpp b/test/she_test.cpp index 79d914e..28ea730 100644 --- a/test/she_test.cpp +++ b/test/she_test.cpp @@ -7,7 +7,7 @@ #include <mcl/she.hpp> using namespace mcl::she; -using namespace mcl::bn_current; +using namespace mcl::bn; SecretKey g_sec; |