CreateMap records map literal construction cost.
(id int64, res ref.Val)
| 195 | |
| 196 | // CreateMap records map literal construction cost. |
| 197 | func (c *Tracker) CreateMap(id int64, res ref.Val) { |
| 198 | c.cost = SafeAdd(c.cost, MapCreateBaseCost) |
| 199 | c.checkLimit() |
| 200 | } |
| 201 | |
| 202 | // CreateStruct records struct/object construction cost. |
| 203 | func (c *Tracker) CreateStruct(id int64, res ref.Val) { |