neko
neko copied to clipboard
Matchsub not matching ^ at start of string
trafficstars
Environment: macOS 10.12.3 (16D32) Haxe 3.4.0 Neko 2.1.0
~/^/.matchSub("1 ", 1)
The above code returns true when using the the JS target, but returns false on the Neko target. Looking at the documentation here, there is no mention of differences on the Neko target regarding the function of ^ for matchSub. If you manually take the substring, like this
~/^/.match("1 ".substr(1))
the result is equal on JS and Neko (true).