Last active
August 29, 2015 14:06
-
-
Save commel/416223b451ae589beb5d to your computer and use it in GitHub Desktop.
Example of Static Extension in Haxe , see also http://haxe.org/manual/lf-static-extension.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Main.StringExtender; | |
class Main { | |
static function main() { | |
trace("hallo".makeUp()); | |
} | |
} | |
class StringExtender { | |
static function makeUp(s:String) { | |
return s.toUpperCase(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
compiles to: