From 336e82d162262c6899b477f7b97032f97a725644 Mon Sep 17 00:00:00 2001 From: Swastik Baranwal Date: Sat, 12 Oct 2019 16:51:06 +0530 Subject: [PATCH] parser: _ warning => error --- compiler/fn.v | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/compiler/fn.v b/compiler/fn.v index 2c49e43f09..a4c5bf4d78 100644 --- a/compiler/fn.v +++ b/compiler/fn.v @@ -242,8 +242,7 @@ fn (p mut Parser) fn_decl() { p.error('function names cannot contain uppercase letters, use snake_case instead') } if f.name[0] == `_` { - // TODO error - p.warn('function names cannot start with `_`') + p.error('function names cannot start with `_`, use snake_case instead') } if f.name.contains('__') { p.error('function names cannot contain double underscores, use single underscores instead')