Value: handle comparisons of runtime_values

Closes #15004
This commit is contained in:
Veikka Tuominen committed 2023-03-21 00:34:12 +02:00
1 parent 773b1c4c5c
commit 9d9815fb9c
2 files changed
+21

No files matched your search

+11
View File
@@ -32,3 +32,14 @@ test "@src used as a comptime parameter" {
const T2 = S.Foo(@src());
try expect(T1 != T2);
}
test "@src in tuple passed to anytype function" {
const S = struct {
fn Foo(a: anytype) u32 {
return a[0].line;
}
};
const l1 = S.Foo(.{@src()});
const l2 = S.Foo(.{@src()});
try expect(l1 != l2);
}