#I want to know the current architecture my zig code is running on ?

1 messages · Page 1 of 1 (latest)

dark mica
#

I know i do pass flags to decide what is the target at compilation phase, but i need to get the value at runtime, not sure how to do that any pointers ?

blazing junco
#

@import("builtin").cpu.arch

dark mica
#

Two questions but is that an enum, i want to send my own values so i will switch on it if it is
Is this valid in 0.17 ?

blazing junco
#

its an enum and yea its valid in 0.17