(ctx *compileContext, isFirstField, isEndField bool)
| 787 | } |
| 788 | |
| 789 | func (c *StructFieldCode) ToAnonymousOpcode(ctx *compileContext, isFirstField, isEndField bool) Opcodes { |
| 790 | field := &Opcode{ |
| 791 | Idx: opcodeOffset(ctx.ptrIndex), |
| 792 | Flags: c.flags() | AnonymousHeadFlags, |
| 793 | Key: c.structKey(ctx), |
| 794 | Offset: uint32(c.offset), |
| 795 | Type: c.typ, |
| 796 | DisplayIdx: ctx.opcodeIndex, |
| 797 | Indent: ctx.indent, |
| 798 | DisplayKey: c.key, |
| 799 | } |
| 800 | ctx.incIndex() |
| 801 | valueCodes := c.toValueOpcodes(ctx) |
| 802 | if isFirstField { |
| 803 | return c.headerOpcodes(ctx, field, valueCodes) |
| 804 | } |
| 805 | return c.fieldOpcodes(ctx, field, valueCodes) |
| 806 | } |
| 807 | |
| 808 | func isEnableStructEndOptimization(value Code) bool { |
| 809 | switch value.Kind() { |
nothing calls this directly
no test coverage detected