-
-
Notifications
You must be signed in to change notification settings - Fork 670
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Neko soft deprecate : split off conditional compilation into separate impl #9350
Conversation
This seems to look good in all cases except |
Well, I'm not sure what this solves, but why not. As for the code duplication, perhaps string quoting could be extracted to a separate class? package haxe.format;
class JsonHelper {
static public function quoteString(string:String, out:Buf):Void;
} Then that could be overridden by platform. Added bonus: by handing string serialization off to the native encoders, it could be used to speed up serialization on Python in general, and on JS and PHP for |
I agree, I might take @back2dos 's recommendation there and just split off a helper method. |
I think we should leave JsonPrinter as it ;) |
Yeah I’m leaning that way now too. I’ll leave it alone for now. |
I'll drop JsonPrinter since it causes some duplicate code issues, and resolving those complicates the intent of this PR too much. |
There's a bug because you have removed code from haxe.Timer that applied to both neko and php targets, without replacements. |
Shouldn't it be handled by the |
Yeah, the default sys case should handle those two. |
Here's a "soft deprecate" effort for neko code in std lib.
Neko shows up in a lot of std lib files as a conditional (
#if neko
). However, neko isn't being actively developed at present, so the extra markup dedicated to it can be construed as clutter.This PR identifies places in the std lib where neko is specified (uniquely) as a conditional on a base std implementation, and splits the neko-specific code into a neko-specific implementation.
This is primarily an aesthetic change, so I'm including a number of old and new people on the review to weigh in.