ACSUtils Wiki

An ACS library for ZDoom-based ports

User Tools

Site Tools


string

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
string [2019/04/19 02:41] korshunstring [2019/04/19 02:43] korshun
Line 11: Line 11:
 ''%%""%%'' is an empty string, i.e. a valid string of length 0. It can be passed to any function and will work as expected. ''%%""%%'' is an empty string, i.e. a valid string of length 0. It can be passed to any function and will work as expected.
  
-===== Comparing strings for equality =====+===== Checking string equality =====
  
 <note warning>Do not use ''=='' to check if strings are equal.</note> <note warning>Do not use ''=='' to check if strings are equal.</note>
Line 21: Line 21:
 ''bool StrEquals(str a, str b)'' ''bool StrEquals(str a, str b)''
  
-And also case-insensitive version:+Internally, this function calls harder to use [[zdoom>StrCmp]], but they could just as well be implemented using combination of [[zdoom>StrLen]] and [[zdoom>GetChar]].
  
-''bool StrIEquals(str a, str b)''+There is also case-insensitive version:
  
-Internallythese functions call harder to use [[zdoom>StrCmp]], but they could just as well be implemented using a combination of [[zdoom>StrLen]] and [[zdoom>GetChar]].+''bool StrIEquals(str astr b)''
  
 +It's implemented using [[zdoom>StrICmp]].
  
  
string.txt · Last modified: 2019/04/19 02:48 by korshun