diff options
| author | zhang san <[email protected]> | 2025-12-08 18:34:25 +0800 |
|---|---|---|
| committer | GitHub <[email protected]> | 2025-12-08 18:34:25 +0800 |
| commit | 69980f8b9d29b38dbd4ddf6373b4b45f3a138409 (patch) | |
| tree | 21dd9a8ce80e3d30192e9ffa56ea39a199bae309 /components/rust/core/src/init.rs | |
| parent | cd1d47b87c5d47e131730e5506eb3ad77d357653 (diff) | |
Adding Rust Language Support for RT-Thread #10910
Diffstat (limited to 'components/rust/core/src/init.rs')
| -rw-r--r-- | components/rust/core/src/init.rs | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/components/rust/core/src/init.rs b/components/rust/core/src/init.rs new file mode 100644 index 0000000000..3f8e326e82 --- /dev/null +++ b/components/rust/core/src/init.rs @@ -0,0 +1,21 @@ +/* + * Copyright (c) 2006-2025, RT-Thread Development Team + * + * SPDX-License-Identifier: Apache-2.0 + * + * Change Logs: + * Date Author Notes + * 2025-09-15 foxglove 1.0 version + */ + +/* Rust component initialization module + * Handles initialization of the Rust component within RT-Thread. + */ + +use crate::println; + +#[no_mangle] +pub extern "C" fn rust_init() -> i32 { + println!("[rust_init]: Rust component initialized!"); + 0 +} |
