Java's SubstrateVM was doing arbitrary execution of code at compile-time, including allocating, and preserving the objects to runtime in 2013 or earlier. Zig only came out in 2016.
See AIM-57: http://publications.csail.mit.edu/ai/browse/0000browse.shtml