Skip to content

Commit

Permalink
Create ExportedCode object from filename
Browse files Browse the repository at this point in the history
  • Loading branch information
benruijl committed Jul 24, 2024
1 parent f8e5f37 commit 4617830
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/evaluate.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1657,6 +1657,14 @@ impl Default for CompileOptions {
}

impl ExportedCode {
/// Create a new exported code object from a source file and function name.
pub fn new(source_filename: String, function_name: String) -> Self {
ExportedCode {
source_filename,
function_name,
}
}

/// Compile the code to a shared library.
pub fn compile(
&self,
Expand Down

0 comments on commit 4617830

Please sign in to comment.