👀 What Happened
I tried this code:
// lib.dn
#define PI 3.14
// main.dn
include "./lib.dn"
fn main() {
println!("PI");
}
I expected to see this happen:
See output: 3.14
Instead, this happened:
Output is PI, so preprocessor didn't processed PI as a defined constant
⚡ Addition Info
Version: v1.2.0 fcd10643
Operating System: Arch Linux x86_64 (Linux 6.15.2-arch1-1)
LLVM IR Code
Not necessary
Intended solution
Keep global mutable preprocessor context between include modules and re-process files if definitions are changed (very bad and unefficient way, need to figure out better solution)
👀 What Happened
I tried this code:
I expected to see this happen:
See output:
3.14Instead, this happened:
Output is
PI, so preprocessor didn't processed PI as a defined constant⚡ Addition Info
Version:
v1.2.0 fcd10643Operating System:
Arch Linux x86_64 (Linux 6.15.2-arch1-1)LLVM IR Code
Not necessaryIntended solution
Keep global mutable preprocessor context between include modules and re-process files if definitions are changed (very bad and unefficient way, need to figure out better solution)