struct capitalization: fix the rest of tests

pull/2159/head
Alexander Medvednikov 2019-09-28 22:26:44 +03:00
parent ed93185cb7
commit d482b1f824
2 changed files with 6 additions and 4 deletions

View File

@ -238,6 +238,7 @@ fn (v mut V) compile() {
println('all .v files:')
println(v.files)
}
/*
if v.pref.is_debug {
println('\nparsers:')
for q in v.parsers {
@ -248,6 +249,7 @@ fn (v mut V) compile() {
println(q)
}
}
*/
// First pass (declarations)
for file in v.files {
for i, p in v.parsers {

View File

@ -10,7 +10,7 @@ const (GDesc = ' The object of Roulette is to pick the number where the spinnin
Otherwise, you will lose your bet.\n')
const (Odd = 'Red' Even = 'Black')
struct options {
struct Options {
long_opt string
short_opt string
}
@ -20,7 +20,7 @@ fn display_help() {
}
fn option_parser() bool {
help := options{'--help', '-h'}
help := Options{'--help', '-h'}
for i := 0; i < os.args.len; i++ {
if os.args[i]== help.long_opt || os.args[i]== help.short_opt {
display_help()
@ -115,7 +115,7 @@ fn is_broke(money int) bool {
println('You\'broke, the game is over..')
return false
} else {
quit := options{'yes', 'y'}
quit := Options{'yes', 'y'}
println('You\'ve $money V. Do you want to quit the casino with your winnings? (y/n)')
line := os.get_line().trim_space().to_lower()
if line== quit.long_opt || line== quit.short_opt {