mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-29 23:04:49 +00:00
Intitialise CodeSection with just the right capacity
This commit is contained in:
parent
7fb09f5768
commit
5bfc0093ec
2 changed files with 3 additions and 7 deletions
|
@ -436,12 +436,6 @@ pub struct CodeSection<'a> {
|
|||
}
|
||||
|
||||
impl<'a> CodeSection<'a> {
|
||||
pub fn new(arena: &'a Bump) -> Self {
|
||||
CodeSection {
|
||||
code_builders: Vec::with_capacity_in(8, arena),
|
||||
}
|
||||
}
|
||||
|
||||
/// Serialize the code builders for all functions, and get code relocations with final offsets
|
||||
pub fn serialize_with_relocs<T: SerialBuffer>(
|
||||
&self,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue