Ticket #83 (accepted enhancement)

Opened 7 weeks ago

Last modified 5 weeks ago

Don't require `is shared` for `def main`

Reported by: Chuck Owned by: Chuck
Priority: major Milestone: Cobra 0.9
Component: Cobra Compiler Version: 0.8.0
Keywords: Cc:

Description

If a class has a parameterless initializer (whether explicit or implied) then don't require that the main be shared:

class Hello
    def main
        print 'Hello'

Generate an error if the class does not have a parameterless constructor.

If there is more than one main method in a program, that's an error due to ambiguity.

Also, provide a command line option to specify which method is the main method like C# does. In which case there is no ambiguity.

Change History

Changed 5 weeks ago by Chuck

  • type changed from defect to enhancement

Changed 5 weeks ago by Chuck

  • milestone set to Cobra 0.9

Changed 5 weeks ago by Chuck

  • owner set to Chuck
  • status changed from new to accepted
Note: See TracTickets for help on using tickets.