Wiki

Ticket #83 (closed enhancement: fixed)

Opened 16 years ago

Last modified 15 years 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 16 years ago by Chuck

  • type changed from defect to enhancement

Changed 16 years ago by Chuck

  • milestone set to Cobra 0.9

Changed 16 years ago by Chuck

  • owner set to Chuck
  • status changed from new to accepted

Changed 15 years ago by hopscc

Can this be closed now ?

Seem to have this covered since changeset:2075

Changed 15 years ago by Chuck

  • status changed from accepted to closed
  • resolution set to fixed

Yep, this was done earlier.

Note: See TracTickets for help on using tickets.