• Yorick Peterse's avatar
    Make module entry points explicit · f96616bf
    Yorick Peterse authored
    The VM no longer depends on a module called "main", instead it starts
    with whatever module is marked as the entry point. The compiler in turn
    sets this entry point to the program to run at the start.
    
    In addition, the way module names are generated has changed a little.
    The main module is no longer always called "main". Instead, if it
    resides in the load path it's named according to that load path. If the
    module is outside of the load path, it's called "main". This ensures
    that for example running runtime/src/std/env.inko results in the module
    being called "std::env" and not "main", preventing the same code from
    running twice.
    f96616bf
Code owners : Yorick Peterse
bytecode_parser.rs 23.1 KB