ecution');

prepareMainThreadExecution();
markBootstrapComplete();

readStdin((code) => {
  // This is necessary for fork() and CJS module compilation.
  // TODO(joyeecheung): pass this with something really internal.
  process._eval = code;

  const print = getOptionValue('--print');
  const loadESM = getOptionValue('--import').length > 0;
  if (getOptionValue('--input-type') === 'module' ||
    (getOptionValue('--experimental-default-type') === 'module' && getOptionValue('--input-type') !== 'commonjs')) {
    evalModule(code, print);
  } else {
    evalScript('[stdin]',
               code,
               getOptionValue('--inspect-brk'),
               print,
               loadESM);
  }
});
