From f6f204387d54b1041d1d7a7f5fda50e7ed89f151 Mon Sep 17 00:00:00 2001 From: Delyan Angelov Date: Fri, 24 Apr 2020 18:44:25 +0300 Subject: [PATCH] cgen: fix for msvc --- vlib/v/gen/cgen.v | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vlib/v/gen/cgen.v b/vlib/v/gen/cgen.v index e21169a080..cfe58821a1 100644 --- a/vlib/v/gen/cgen.v +++ b/vlib/v/gen/cgen.v @@ -2409,11 +2409,11 @@ fn (mut g Gen) string_inter_literal(node ast.StringInterLiteral) { g.write(',0).str') } else if g.typ( node.expr_types[i] ).starts_with('Option') { str_fn_name := 'Option_str' - g.write('${str_fn_name}((Option)') + g.write('${str_fn_name}(*(Option*)&') g.expr(expr) g.write(')') g.write('.len, ') - g.write('${str_fn_name}((Option)') + g.write('${str_fn_name}(*(Option*)&') g.expr(expr) g.write(').str') } else {