@@ -723,7 +723,7 @@ pub const SourceMappings = struct {
723723 /// The default assumes that the first filename added is the root file.
724724 /// The value should be set to the correct offset if that assumption does not hold.
725725 root_filename_offset : u32 = 0 ,
726- source_node_pool : std .heap .MemoryPool (Sources .Node ) = std . heap . MemoryPool ( Sources . Node ). init ( std . heap . page_allocator ) ,
726+ source_node_pool : std .heap .MemoryPool (Sources .Node ) = .empty ,
727727 end_line : usize = 0 ,
728728
729729 const sourceCompare = struct {
@@ -742,7 +742,7 @@ pub const SourceMappings = struct {
742742
743743 pub fn deinit (self : * SourceMappings , allocator : Allocator ) void {
744744 self .files .deinit (allocator );
745- self .source_node_pool .deinit ();
745+ self .source_node_pool .deinit (std . heap . page_allocator );
746746 }
747747
748748 /// Find the node that 'contains' the `line`, i.e. the node's start_line is
@@ -823,7 +823,7 @@ pub const SourceMappings = struct {
823823 .filename_offset = filename_offset ,
824824 };
825825 var entry = self .sources .getEntryFor (key );
826- var new_node = try self .source_node_pool .create ();
826+ var new_node = try self .source_node_pool .create (std . heap . page_allocator );
827827 new_node .key = key ;
828828 entry .set (new_node );
829829 }
@@ -869,7 +869,7 @@ pub const SourceMappings = struct {
869869 .filename_offset = node .key .filename_offset ,
870870 };
871871 var entry = self .sources .getEntryFor (key );
872- var new_node = try self .source_node_pool .create ();
872+ var new_node = try self .source_node_pool .create (std . heap . page_allocator );
873873 new_node .key = key ;
874874 entry .set (new_node );
875875 node = new_node ;
0 commit comments