(in *utils.InputBuf, bnlen int)
| 23 | } |
| 24 | |
| 25 | func deserializeCoef(in *utils.InputBuf, bnlen int) (*big.Int, uint8, uint64) { |
| 26 | coefType := in.ReadUint8() |
| 27 | if coefType == 1 { |
| 28 | return in.ReadBigInt(bnlen), 1, 0 |
| 29 | } else if coefType == 2 { |
| 30 | return big.NewInt(0), 2, 0 |
| 31 | } else { |
| 32 | return big.NewInt(0), 3, in.ReadUint64() |
| 33 | } |
| 34 | } |
| 35 | |
| 36 | // Serialize converts a RootCircuit into a byte array for storage or transmission. |
| 37 | func (rc *RootCircuit) Serialize() []byte { |
no test coverage detected