lib-vt: update header comments

This commit is contained in:
Mitchell Hashimoto
2025-09-24 12:48:41 -07:00
parent 390f72accc
commit 232b1898fa
2 changed files with 15 additions and 3 deletions

View File

@@ -6,7 +6,7 @@ const CAllocator = lib_alloc.Allocator;
const osc = @import("osc.zig");
/// C: GhosttyOscParser
pub const OscParser = *osc.Parser;
pub const OscParser = ?*osc.Parser;
/// C: GhosttyResult
pub const Result = enum(c_int) {
@@ -26,8 +26,9 @@ pub fn osc_new(
return .success;
}
pub fn osc_free(parser: OscParser) callconv(.c) void {
pub fn osc_free(parser_: OscParser) callconv(.c) void {
// C-built parsers always have an associated allocator.
const parser = parser_ orelse return;
const alloc = parser.alloc.?;
parser.deinit();
alloc.destroy(parser);