2 ; Ullrich von Bassewitz, 11.06.1998
4 ; char* strpbrk (const char* s1, const char* s2);
9 .importzp ptr1, ptr2, tmp1, tmp2, tmp3
20 L1: lda (ptr1),y ; get next char from s1
26 L2: sty tmp3 ; save index into s1
28 ldy #0 ; get index into s2
36 ; The character was not found in s2. Increment the counter and start over
38 L4: ldy tmp3 ; reload index
44 ; A character was found. Calculate a pointer to this char in s1 and return it.
47 lda tmp3 ; get y offset
54 ; None of the characters in s2 was found - return NULL