Skip to content
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

Bug during haxe --macro Field index for SSL_IS_SERVER not found #11631

Closed
yuxiaomao opened this issue Apr 8, 2024 · 1 comment · Fixed by #11636
Closed

Bug during haxe --macro Field index for SSL_IS_SERVER not found #11631

yuxiaomao opened this issue Apr 8, 2024 · 1 comment · Fixed by #11636

Comments

@yuxiaomao
Copy link
Contributor

yuxiaomao commented Apr 8, 2024

Run the following code with haxe --macro Config.main() result in error Field index for SSL_IS_SERVER not found on prototype mbedtls._SslEndpoint.SslEndpoint_Impl_
Since 944d4fd ( #11481 )

It works fine with haxe --run Config.

class Config {
	public static function main() {
		Sys.println("Config...");
	}

	public static function updateHaxeLinux() {
		new haxe.Http("https://build.haxe.org/builds/haxe/linux64/");
	}
}
@kLabz
Copy link
Contributor

kLabz commented Apr 8, 2024

Note that it's because of

@:native("mbedtls.SslEndpoint")
extern enum abstract SslEndpoint(Int) {
var SSL_IS_CLIENT;
var SSL_IS_SERVER;
}

Which seems to indicate we do need some "@:native" behavior for macro (but probably only for std things)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants