disable the snake_case const warning for now

pull/2316/head
Alexander Medvednikov 2019-10-12 22:38:06 +03:00
parent a76165828b
commit 208f17a73a
2 changed files with 5 additions and 5 deletions

View File

@ -518,9 +518,9 @@ fn (p mut Parser) const_decl() {
continue
}
mut name := p.check_name() // `Age = 20`
if !p.pref.building_v && p.mod != 'os' && contains_capital(name) {
p.warn('const names cannot contain uppercase letters, use snake_case instead')
}
//if !p.pref.building_v && p.mod != 'os' && contains_capital(name) {
//p.warn('const names cannot contain uppercase letters, use snake_case instead')
//}
name = p.prepend_mod(name)
mut typ := ''
if p.is_vh {

View File

@ -10,9 +10,9 @@ import (
fn test_import() {
assert os.SUCCESS == os.SUCCESS &&
t.MonthDays[0] == t.MonthDays[0] &&
t.month_days[0] == t.month_days[0] &&
s2.Size == s2.Size &&
math.Pi == math.Pi &&
math.pi == math.pi &&
l.INFO == l.INFO &&
s5.Size == s5.Size
}