aboutsummaryrefslogtreecommitdiff
path: root/challenge-307/deadmarshal/zig/ch2/src/root.zig
diff options
context:
space:
mode:
authordeadmarshal <adeadmarshal@gmail.com>2025-02-04 20:32:22 +0330
committerdeadmarshal <adeadmarshal@gmail.com>2025-02-04 20:32:22 +0330
commitc04cf6be6621e9be28c104d6fe295b71b0699fb8 (patch)
treeb74e4c49669ed8ffff9b9b66f4bd64f492485868 /challenge-307/deadmarshal/zig/ch2/src/root.zig
parentaaab417272f7ae13ade34c68a033d2b1214886d3 (diff)
downloadperlweeklychallenge-club-c04cf6be6621e9be28c104d6fe295b71b0699fb8.tar.gz
perlweeklychallenge-club-c04cf6be6621e9be28c104d6fe295b71b0699fb8.tar.bz2
perlweeklychallenge-club-c04cf6be6621e9be28c104d6fe295b71b0699fb8.zip
TWC307
Diffstat (limited to 'challenge-307/deadmarshal/zig/ch2/src/root.zig')
-rw-r--r--challenge-307/deadmarshal/zig/ch2/src/root.zig10
1 files changed, 10 insertions, 0 deletions
diff --git a/challenge-307/deadmarshal/zig/ch2/src/root.zig b/challenge-307/deadmarshal/zig/ch2/src/root.zig
new file mode 100644
index 0000000000..ecfeade1a3
--- /dev/null
+++ b/challenge-307/deadmarshal/zig/ch2/src/root.zig
@@ -0,0 +1,10 @@
+const std = @import("std");
+const testing = std.testing;
+
+export fn add(a: i32, b: i32) i32 {
+ return a + b;
+}
+
+test "basic add functionality" {
+ try testing.expect(add(3, 7) == 10);
+}