| ... | ... | @@ -112,17 +112,17 @@ pub const DecoderState = struct { |
| 112 | 112 | .lzma_props = lzma_props, |
| 113 | 113 | .unpacked_size = unpacked_size, |
| 114 | 114 | .literal_probs = try Vec2D(u16).init(allocator, 0x400, .{ @as(usize, 1) << (lzma_props.lc + lzma_props.lp), 0x300 }), |
| 115 | | .pos_slot_decoder = .{.{}} ** 4, |
| 115 | .pos_slot_decoder = @splat(.{}), |
| 116 | 116 | .align_decoder = .{}, |
| 117 | | .pos_decoders = .{0x400} ** 115, |
| 118 | | .is_match = .{0x400} ** 192, |
| 119 | | .is_rep = .{0x400} ** 12, |
| 120 | | .is_rep_g0 = .{0x400} ** 12, |
| 121 | | .is_rep_g1 = .{0x400} ** 12, |
| 122 | | .is_rep_g2 = .{0x400} ** 12, |
| 123 | | .is_rep_0long = .{0x400} ** 192, |
| 117 | .pos_decoders = @splat(0x400), |
| 118 | .is_match = @splat(0x400), |
| 119 | .is_rep = @splat(0x400), |
| 120 | .is_rep_g0 = @splat(0x400), |
| 121 | .is_rep_g1 = @splat(0x400), |
| 122 | .is_rep_g2 = @splat(0x400), |
| 123 | .is_rep_0long = @splat(0x400), |
| 124 | 124 | .state = 0, |
| 125 | | .rep = .{0} ** 4, |
| 125 | .rep = @splat(0), |
| 126 | 126 | .len_decoder = .{}, |
| 127 | 127 | .rep_len_decoder = .{}, |
| 128 | 128 | }; |
| ... | ... | @@ -145,15 +145,15 @@ pub const DecoderState = struct { |
| 145 | 145 | self.lzma_props = new_props; |
| 146 | 146 | for (&self.pos_slot_decoder) |*t| t.reset(); |
| 147 | 147 | self.align_decoder.reset(); |
| 148 | | self.pos_decoders = .{0x400} ** 115; |
| 149 | | self.is_match = .{0x400} ** 192; |
| 150 | | self.is_rep = .{0x400} ** 12; |
| 151 | | self.is_rep_g0 = .{0x400} ** 12; |
| 152 | | self.is_rep_g1 = .{0x400} ** 12; |
| 153 | | self.is_rep_g2 = .{0x400} ** 12; |
| 154 | | self.is_rep_0long = .{0x400} ** 192; |
| 148 | self.pos_decoders = @splat(0x400); |
| 149 | self.is_match = @splat(0x400); |
| 150 | self.is_rep = @splat(0x400); |
| 151 | self.is_rep_g0 = @splat(0x400); |
| 152 | self.is_rep_g1 = @splat(0x400); |
| 153 | self.is_rep_g2 = @splat(0x400); |
| 154 | self.is_rep_0long = @splat(0x400); |
| 155 | 155 | self.state = 0; |
| 156 | | self.rep = .{0} ** 4; |
| 156 | self.rep = @splat(0); |
| 157 | 157 | self.len_decoder.reset(); |
| 158 | 158 | self.rep_len_decoder.reset(); |
| 159 | 159 | } |