Skip to main content

rust_workspaced/
lib.rs

1// SPDX-FileCopyrightText: Elio Severo Junior <elioseverojunior@gmail.com>
2//
3// SPDX-License-Identifier: MIT OR Apache-2.0
4
5#[must_use]
6pub const fn add(left: u64, right: u64) -> u64 {
7    left + right
8}
9
10#[cfg(test)]
11mod tests {
12    use super::*;
13
14    #[test]
15    fn it_works() {
16        let result = add(2, 2);
17        assert_eq!(result, 4);
18    }
19}