soma.cell

There is no cell type X { fields { ... } }

Pitfall 9 of writing Soma, the programming language: a habit from another language, or a rule that surprises, with what the Soma compiler answers and the form to write.

Records are plain map-shaped values. Construct them with a literal:

let g = Game { bet: 10, pot: 0 }   // a field-accessible value (a Map)
g.bet = 20                          // mutate fields in place
let b = g.bet
return is_a(g, "Game")              // true — record literals carry _type

Use cell type X { variants { ... } } only for sum types (tagged unions).