mirror of
https://github.com/odin-lang/Odin.git
synced 2026-01-05 04:27:51 +00:00
Allow nested para-poly procedures
This commit is contained in:
@@ -2,11 +2,12 @@ import (
|
||||
"fmt.odin";
|
||||
)
|
||||
|
||||
proc new_type(T: type) -> ^T {
|
||||
return ^T(alloc(size_of(T), align_of(T)));
|
||||
}
|
||||
|
||||
proc main() {
|
||||
proc new_type(T: type) -> ^T {
|
||||
return ^T(alloc(size_of(T), align_of(T)));
|
||||
}
|
||||
|
||||
var ptr = new_type(int);
|
||||
ptr^ = 123;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user