From 549d7a487d0195f203bf3fbf862ee5aa38c5f92e Mon Sep 17 00:00:00 2001 From: Alexander Medvednikov Date: Sat, 11 Jul 2020 11:51:58 +0200 Subject: [PATCH] tests: fix scanner_test.v --- vlib/v/scanner/scanner_test.v | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/vlib/v/scanner/scanner_test.v b/vlib/v/scanner/scanner_test.v index 4e36456030..90014d89ba 100644 --- a/vlib/v/scanner/scanner_test.v +++ b/vlib/v/scanner/scanner_test.v @@ -4,9 +4,10 @@ module scanner import v.token +import v.pref fn scan_kinds(text string) []token.Kind { - mut scanner := new_scanner(text, .skip_comments, false) + mut scanner := new_scanner(text, .skip_comments, &pref.Preferences{}) mut token_kinds := []token.Kind{} for { tok := scanner.scan() @@ -90,7 +91,7 @@ fn test_ref_ref_foo() { assert result[0] == .amp assert result[1] == .amp assert result[2] == .name -} +} fn test_array_of_ref_ref_foo() { result := scan_kinds('[]&&foo')