(ctx context.Context, what string)
| 232 | } |
| 233 | |
| 234 | func (tmplContext *BulkTemplateContext) binExtractInt24(ctx context.Context, what string) (value int32) { |
| 235 | bin, success := tmplContext.binExtract(ctx, what, 3) |
| 236 | if !success { |
| 237 | return |
| 238 | } |
| 239 | value = int32(bin[0]) |
| 240 | value = value | (int32(bin[1]) << 8) |
| 241 | msb := int8(bin[2]) |
| 242 | msbSignExtended := int32(msb) |
| 243 | value = value | (msbSignExtended << 16) |
| 244 | return value |
| 245 | } |
| 246 | |
| 247 | func (tmplContext *BulkTemplateContext) binExtractUint24(ctx context.Context, what string) (value uint32) { |
| 248 | bin, success := tmplContext.binExtract(ctx, what, 3) |
no test coverage detected