kvisc/dos/str/strchr.k

19 lines
323 B
Plaintext

; The OS/K Team licenses this file to you under the MIT license.
; See the LICENSE file in the project root for more information.
;
; char *strchrnul(const char *str, int ch)
;
strchrnul:
ret
;
; char *strchr(const char *str, int ch)
;
strchr:
call strchrnul
test b[rax], b[rax]
cmovz rax, 0
ret