src/vm/oba_compiler.c
static int addConstant(Compiler* compiler, Value value) {
  if (IS_OBJ(value)) obaPushRoot(compiler->vm, AS_OBJ(value));
  writeValueBuffer(compiler->vm, &compiler->function->chunk.constants, value);
  if (IS_OBJ(value)) obaPopRoot(compiler->vm);
  return compiler->function->chunk.constants.count - 1;
}
// Adds [value] the the Vm's constant pool.
// Returns the address of the new constant within the pool.
Adds [value] the the Vm's constant pool.
Returns the address of the new constant within the pool.
Adds [ value ] the the Vm ' s constant pool . Returns the address of the new constant within the pool .
static int addConstant(Compiler* compiler, Value value) {
  if (IS_OBJ(value)) obaPushRoot(compiler->vm, AS_OBJ(value));
  writeValueBuffer(compiler->vm, &compiler->function->chunk.constants, value);
  if (IS_OBJ(value)) obaPopRoot(compiler->vm);
  return compiler->function->chunk.constants.count - 1;
}
static int addConstant ( Compiler * compiler , Value value ) { if ( IS_OBJ ( value ) ) obaPushRoot ( compiler -> vm , AS_OBJ ( value ) ) ; writeValueBuffer ( compiler -> vm , & compiler -> function -> chunk . constants , value ) ; if ( IS_OBJ ( value ) ) obaPopRoot ( compiler -> vm ) ; return compiler -> function -> chunk . constants . count - 1 ; }
Adds [value] the the Vm's constant pool.
Adds [ value ] the the Vm ' s constant pool .