7 ms·
Functions are public by default. You could leave that out. The main function has to be static and will serve as the entrance point of the program, not the clas
by boofar 14y ago
Functions are public by default. You could leave that out.
The main function has to be static and will serve as the entrance point of the program, not the class.
So this might just look like too much when in fact this is just a very small code sample.
Did I address some of your concerns, or did I miss the point entirely? Just curious.
- jonpacker 14y agoI think his comment could be refrased as "This language looks like Java"
- clemos 14y agoWell at least it doesn't look like PHP...
- clemos 14y agoAlso, IMHO the fact that Haxe looks familiar to people coming from Javascript, ActionScript, or Java is a plus.
- WiseWeasel 14y agoAgreed. I'd wager there are substantially more people learning JavaScript these days than PHP, not that PHP looks too foreign, relatively speaking.
- clemos 14y agoActually functions are private by default. "static function main()" seems to work as an entrance point, though, which makes sense somehow...
- boofar 14y agoI'm sorry, you're correct of course! Private is the sane default obviously.