v/vlib/v/gen/native/macho_test.v

22 lines
333 B
V
Raw Normal View History

import os
import v.gen.native
2021-03-05 15:52:34 +01:00
import v.pref
import v.ast
2021-03-05 15:52:34 +01:00
fn test_macho() {
2021-08-28 08:35:39 +02:00
os.chdir(os.temp_dir()) or {}
mut g := native.Gen{
pref: &pref.Preferences{
arch: .amd64
}
2021-03-05 15:52:34 +01:00
out_name: 'test.bin'
table: ast.new_table()
code_gen: native.Amd64{
2021-09-09 22:00:54 +02:00
g: 0
}
labels: 0
2021-03-05 15:52:34 +01:00
}
g.generate_macho_header()
g.generate_macho_footer()
}