diff --git a/src/hulk/hurl/a1.d b/src/hulk/hurl/a1.d index df1d786..9a9c483 100644 --- a/src/hulk/hurl/a1.d +++ b/src/hulk/hurl/a1.d @@ -50,4 +50,15 @@ struct A1 return cast(void *)address; } + + /** + * Allocate memory to store an instance of a given type. + * + * @return Address of allocated memory. This address will always be aligned + * to a multiple of 16 bytes. + */ + public static T * allocate(T)() + { + return cast(T *)allocate(T.sizeof); + } }