1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

parser: report unused expression error in if and or blocks (#6953)

This commit is contained in:
Takahiro Yaota
2020-11-26 08:28:41 +09:00
committed by GitHub
parent 2957541e48
commit 258f8f6af9
7 changed files with 40 additions and 8 deletions

View File

@@ -1650,7 +1650,7 @@ pub fn (mut re RE) match_base(in_txt byteptr, in_txt_len int ) (int,int) {
// manage ist_dot_char
m_state == .end
m_state = .end
break
//return no_match_found,0
}
@@ -1822,7 +1822,7 @@ pub fn (mut re RE) match_base(in_txt byteptr, in_txt_len int ) (int,int) {
//println("ist_or_branch False pc: $pc")
}
re.prog[pc].reset()
m_state == .ist_load
m_state = .ist_load
continue
}