build: add Sendable to protocol swift gen

This commit is contained in:
Peter Steinberger
2026-01-04 06:46:09 +00:00
parent c62fd2379a
commit 16cd9a4189
2 changed files with 62 additions and 62 deletions

View File

@@ -106,7 +106,7 @@ function emitStruct(name: string, schema: JsonSchema): string {
const props = schema.properties ?? {};
const required = new Set(schema.required ?? []);
const lines: string[] = [];
lines.push(`public struct ${name}: Codable {`);
lines.push(`public struct ${name}: Codable, Sendable {`);
if (Object.keys(props).length === 0) {
lines.push("}\n");
return lines.join("\n");