Skip to content

Commit e8c44b0

Browse files
Update irbuild-str.test
1 parent 30c8d69 commit e8c44b0

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

mypyc/test-data/irbuild-str.test

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -512,7 +512,17 @@ def do_count(s: str) -> int:
512512
def do_count(s):
513513
s, r0 :: str
514514
r0 = 'x'
515-
return CPyStr_CountAll(s, r0)
515+
return CPyStr_Count(s, r0, 0)
516+
517+
[case testCountStart]
518+
def do_count(s: str, start: int) -> int:
519+
return s.count("x", start)
520+
[out]
521+
def do_count(s, start):
522+
s, r0 :: str
523+
start :: Py_ssize_t
524+
r0 = 'x'
525+
return CPyStr_Count(s, r0, start)
516526

517527
[case testCountStartEnd]
518528
def do_count(s: str, start: int, end: int) -> int:

0 commit comments

Comments
 (0)