Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
ctor 0.1.8 - Docs.rs
[go: Go Back, main page]

ctor 0.1.8

__attribute__((constructor)) for Rust
Documentation

Procedural macro for defining global constructor/destructor functions.

This provides module initialization/teardown functions for Rust (like __attribute__((constructor)) in C/C++) for Linux, OSX, and Windows via the #[ctor] and #[dtor] macros.

This library works and has been tested for Linux, OSX and Windows. This library will also work as expected in both bin and cdylib outputs, ie: the ctor and dtor will run at executable or library startup/shutdown respectively.

This library currently requires Rust > 1.31.0 at a minimum for the procedural macro support.