Skip to content

Commit cd1e428

Browse files
committed
v2: eval; live; arm64 fixes
1 parent 171afcb commit cd1e428

21 files changed

Lines changed: 2594 additions & 225 deletions

File tree

‎vlib/v2/builder/builder.v‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -590,7 +590,7 @@ fn (b &Builder) default_output_name() string {
590590
if b.user_files.len == 0 {
591591
return 'out'
592592
}
593-
last_input := b.user_files.last().trim_right('/\\')
593+
last_input := b.user_files[b.user_files.len - 1].trim_right('/\\')
594594
if last_input.len == 0 || last_input == '.' {
595595
cwd := os.getwd()
596596
base := os.file_name(cwd)
@@ -1300,6 +1300,11 @@ fn (mut b Builder) gen_native(backend_arch pref.Arch) {
13001300
mut ssa_builder := ssa.Builder.new_with_env(mod, b.env)
13011301
mut native_sw := time.new_stopwatch()
13021302

1303+
// In hot_fn mode, only build the target function body (skip all others)
1304+
if b.pref.hot_fn.len > 0 {
1305+
ssa_builder.hot_fn = b.pref.hot_fn
1306+
}
1307+
13031308
// Build all files together with proper multi-file ordering
13041309
mut stage_start := native_sw.elapsed()
13051310
ssa_builder.build_all(b.files)

0 commit comments

Comments
 (0)