(&mut self, version: &ClassfileVersion)
| 28 | } |
| 29 | |
| 30 | pub fn write_classfile_version(&mut self, version: &ClassfileVersion) -> Result<usize, Error> { |
| 31 | self.write_u16(version.minor_version) |
| 32 | .and(self.write_u16(version.major_version)) |
| 33 | } |
| 34 | |
| 35 | pub fn write_constant_pool(&mut self, cp: &ConstantPool) -> Result<usize, Error> { |
| 36 | cp.constants.iter().fold(self.write_u16(cp.cp_len() as u16), |acc, x| { |