Skip to content

Commit

Permalink
Don't use borrows of Option
Browse files Browse the repository at this point in the history
A `ref Option[String]` makes no sense as we can just use `Option[String]`
instead, producing the exact same result runtime wise.
  • Loading branch information
yorickpeterse committed Jan 21, 2025
1 parent a8dd525 commit bc0863e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions std/test/compiler/test_compile_time_variables.inko
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ fn compile(
input: ref Path,
output: ref Path,
directory: ref Path,
define: ref Option[String],
define: Option[String],
) -> Result[Nil, String] {
let cmd = Command.new(compiler_path)

Expand Down Expand Up @@ -60,7 +60,7 @@ fn run(id: Int, define: Option[String]) -> Result[String, String] {

let output = dir.join('test')

try compile(input, output, dir, define)
try compile(input, output, dir, define.clone)

let cmd = Command.new(output)

Expand Down

0 comments on commit bc0863e

Please sign in to comment.