mirror of
https://github.com/data61/MP-SPDZ.git
synced 2026-01-13 23:48:15 -05:00
23 lines
335 B
C++
23 lines
335 B
C++
/*
|
|
* FixInput.cpp
|
|
*
|
|
*/
|
|
|
|
#include "FixInput.h"
|
|
|
|
template<>
|
|
void FixInput_<Integer>::read(std::istream& in, const int* params)
|
|
{
|
|
double x;
|
|
in >> x;
|
|
items[0] = x * (1 << *params);
|
|
}
|
|
|
|
template<>
|
|
void FixInput_<bigint>::read(std::istream& in, const int* params)
|
|
{
|
|
mpf_class x;
|
|
in >> x;
|
|
items[0] = x << *params;
|
|
}
|