1
Fork 0

Merge commit '59a81c2ca1' into subtree-update_cg_gcc_2025_01_12

This commit is contained in:
Antoni Boucher 2025-01-13 10:53:58 -05:00
commit 06f0a9bc78
49 changed files with 825 additions and 1519 deletions

View file

@ -0,0 +1,14 @@
# This file is automatically @generated by Cargo.
# It is not intended for manual editing.
version = 4
[[package]]
name = "hello_world"
version = "0.0.0"
dependencies = [
"mylib",
]
[[package]]
name = "mylib"
version = "0.1.0"

View file

@ -1,4 +1,12 @@
[package]
name = "hello_world"
edition = "2024"
[dependencies]
mylib = { path = "mylib" }
[profile.dev]
lto = "thin"
[profile.release]
lto = "fat"

View file

@ -0,0 +1,5 @@
# This file is automatically @generated by Cargo.
# It is not intended for manual editing.
[[package]]
name = "mylib"
version = "0.1.0"

View file

@ -0,0 +1,9 @@
[package]
name = "mylib"
version = "0.1.0"
authors = ["Antoni Boucher <bouanto@zoho.com>"]
edition = "2018"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]

View file

@ -0,0 +1,7 @@
pub fn my_func(a: i32, b: i32) -> i32 {
let mut res = a;
for i in a..b {
res += i;
}
res
}

View file

@ -1,3 +1,5 @@
use mylib::my_func;
fn main() {
println!("Hello, world!");
println!("{}", my_func(5, 10));
}