Bug fix and optimization of WideString length comparison with zero
- Fixed optimization
Length(W)=0
->(Pointer(W)=nil) or (PLongword(Pointer(W)-4)^=0)
forWideString
Before this MR it was like this:Length(W)=0
->(Pointer(W)=nil) or (PSizeInt(Pointer(W)-SizeOf(SizeInt))^=0)
- Optimized the comparison of a
WideString
variable with''
:
W=''
->Length(W)=0
->(Pointer(W)=nil) or (PLongword(Pointer(W)-4)^=0)
Edited by Sergey Larin