From 4d60fa5632246d5e1c355573dc0fd0e85ca3dcd3 Mon Sep 17 00:00:00 2001 From: Ophestra Date: Tue, 19 May 2026 01:26:21 +0900 Subject: internal/rosa: evaluate packages late This also enables concurrent evaluation. Signed-off-by: Ophestra --- internal/rosa/rosa.go | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'internal/rosa/rosa.go') diff --git a/internal/rosa/rosa.go b/internal/rosa/rosa.go index dde85e00..209b8942 100644 --- a/internal/rosa/rosa.go +++ b/internal/rosa/rosa.go @@ -614,11 +614,11 @@ var native S // Native returns the global [S]. func Native() *S { return &native } -// evalTime is the duration of the initial built-in evaluation. -var evalTime time.Duration +// parseTime is the duration of early parsing of built-in azalea expressions. +var parseTime time.Duration -// EvalTime returns the duration of the initial built-in evaluation. -func EvalTime() time.Duration { return evalTime } +// ParseTime returns the time taken by early parsing of built-in azalea expressions. +func ParseTime() time.Duration { return parseTime } // nativeB is the backing directory of built-in azalea-based [Artifact] // implementations. @@ -632,9 +632,9 @@ func init() { panic(err) } t := time.Now() - if err = native.EvaluateFS(sub); err != nil { + if err = native.RegisterFS(sub); err != nil { println(err.Error()) os.Exit(1) } - evalTime = time.Since(t) + parseTime = time.Since(t) } -- cgit v1.3.1