* @param options - the values for compiler options
* @return a new entry point generator.
*/
private EntryPointGenerator makeEntryPointGenerator(CompilationOptions options) {
EntryPointGenerator newEntryPointGenerator = programManager.makeEntryPointGenerator();
for (final StatusListener statusListener : statusListeners) {
newEntryPointGenerator.addStatusListener(statusListener);
}
if (options != null) {
newEntryPointGenerator.setForceCodeRegen(options.isForceCodeRegeneration());
newEntryPointGenerator.setForImmediateUse(options.isForImmediateUse());
// TODOEL: Should we provide some kind of warning if inapplicable options are set?
// eg. Can't override the foreign context for a module.
// ignoreCompiledModuleInfo doesn't apply.
}