Skip to content

Commit daf7281

Browse files
threadpool: fix swift wrapper errors due to n_threads int type cleanup
1 parent 88529ea commit daf7281

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

examples/llama.swiftui/llama.cpp.swift/LibLlama.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,8 @@ actor LlamaContext {
7171
var ctx_params = llama_context_default_params()
7272
ctx_params.seed = 1234
7373
ctx_params.n_ctx = 2048
74-
ctx_params.n_threads = UInt32(n_threads)
75-
ctx_params.n_threads_batch = UInt32(n_threads)
74+
ctx_params.n_threads = Int32(n_threads)
75+
ctx_params.n_threads_batch = Int32(n_threads)
7676

7777
let context = llama_new_context_with_model(model, ctx_params)
7878
guard let context else {

0 commit comments

Comments
 (0)