Implement Ed25519 (#2297)

* Implement Ed25519
* Overloading addition with a pointer would not work.
* Added @addr macro.

---------

Co-authored-by: Christoffer Lerno <christoffer@aegik.com>
This commit is contained in:
Airtz
2025-07-19 01:13:15 +02:00
committed by GitHub
parent e9aee55714
commit b1a22b5002
6 changed files with 786 additions and 32 deletions

View File

@@ -96,6 +96,14 @@ macro anycast(any v, $Type) @builtin
return ($Type*)v.ptr;
}
macro @addr(#val) @builtin
{
$if $defined(&#val):
return &#val;
$else
return &&#val;
$endif
}
fn bool print_backtrace(String message, int backtraces_to_ignore) @if (env::NATIVE_STACKTRACE) => @stack_mem(0x1100; Allocator smem)
{
void*[256] buffer;