Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
when there is an implicit main and an explicit main, there should be a reasonable error given by the compiler #189
class Test def self.main(args:String):void puts "This is a test" end end puts "hello"
currently does this
which understandably doesn't work.
This should be a compiler error.
file name & class name differ, maybe then it's ok. eg
class Guitar def play puts "twang" end def self.main(args:string):void g = Guitar.new g.play end end rhythm = Guitar.new lead = Guitar.new rhythm.play lead.play
Rockem.class w/ main as the implicit main, and Guitar w/ its explicit main.