mirror of
https://github.com/oven-sh/bun
synced 2026-02-13 20:39:05 +00:00
fix(nitro) fix sourcemaps and JSSink closing (#5422)
* fix JSSink progress on sourcemap checking * fix sourcemaps * update JSSink fix * undo + tests --------- Co-authored-by: Jarred Sumner <jarred@jarredsumner.com>
This commit is contained in:
@@ -940,7 +940,7 @@ pub const LineOffsetTable = struct {
|
||||
contents.ptr,
|
||||
)) - line_byte_offset),
|
||||
);
|
||||
byte_offset_to_first_non_ascii = line_byte_offset;
|
||||
byte_offset_to_first_non_ascii = column_byte_offset;
|
||||
}
|
||||
|
||||
// Update the per-byte column offsets
|
||||
@@ -1405,7 +1405,7 @@ pub const Chunk = struct {
|
||||
// Use the line to compute the column
|
||||
var original_column = loc.start - @as(i32, @intCast(line.byte_offset_to_start_of_line));
|
||||
if (line.columns_for_non_ascii.len > 0 and original_column >= @as(i32, @intCast(line.byte_offset_to_first_non_ascii))) {
|
||||
original_column = line.columns_for_non_ascii.ptr[@as(u32, @intCast(original_column)) - line.byte_offset_to_first_non_ascii];
|
||||
original_column = line.columns_for_non_ascii.slice()[@as(u32, @intCast(original_column)) - line.byte_offset_to_first_non_ascii];
|
||||
}
|
||||
|
||||
b.updateGeneratedLineAndColumn(output);
|
||||
|
||||
Reference in New Issue
Block a user