File tree Expand file tree Collapse file tree
typed-racket-lib/typed-racket/base-env
typed-racket-test/unit-tests Expand file tree Collapse file tree Original file line number Diff line number Diff line change 6868 (->opt -SingleFlonum -Real [-SingleFlonum] (-lst -SingleFlonum))
6969 (->opt -InexactReal -Real [-InexactReal] (-lst -InexactReal))
7070 (->opt -Real -Real [-Real] (-lst -Real)))]
71+ ;; inclusive-range
72+ [(make-template-identifier 'inclusive-range-proc 'racket/list )
73+ (cl->*
74+ (->opt -PosInt -Byte [-Int] (-lst -PosByte))
75+ (->opt -Nat -Byte [-Int] (-lst -Byte))
76+ (->opt -PosInt -Index [-Int] (-lst -PosIndex))
77+ (->opt -Nat -Index [-Int] (-lst -Index))
78+ (->opt -Nat -NonNegFixnum [-Int] (-lst -NonNegFixnum))
79+ (->opt -PosInt -Fixnum [-Nat] (-lst -PosFixnum))
80+ (->opt -Nat -Fixnum [-Nat] (-lst -NonNegFixnum))
81+ (->opt -Nat -Nat [-Int] (-lst -Nat))
82+ (->opt -PosInt -Int [-Nat] (-lst -PosInt))
83+ (->opt -Nat -Int [-Nat] (-lst -Nat))
84+ (->opt -Int -Real [-Int] (-lst -Int))
85+ (->opt -Rat -Real [-Rat] (-lst -Rat))
86+ (->opt -Flonum -Real [-Flonum] (-lst -Flonum))
87+ (->opt -SingleFlonum -Real [-SingleFlonum] (-lst -SingleFlonum))
88+ (->opt -InexactReal -Real [-InexactReal] (-lst -InexactReal))
89+ (->opt -Real -Real [-Real] (-lst -Real)))]
7190 ;; unsafe-normalise-inputs
7291 [(make-template-identifier 'unsafe-normalise-inputs 'racket/private/for )
7392 (-poly (a)
Original file line number Diff line number Diff line change 27542754 [tc-e (in-combinations '(1 2 1 ) 2 ) (-seq (-lst -PosByte))]
27552755 [tc-e (permutations '(a b c d)) (-lst (-lst (one-of/c 'a 'b 'c 'd )))]
27562756 [tc-e (in-permutations '(a b c d)) (-seq (-lst (one-of/c 'a 'b 'c 'd )))]
2757+ [tc-e (inclusive-range 1 5 ) (-lst -PosByte)]
2758+ [tc-e (inclusive-range 1 5 2 ) (-lst -PosByte)]
2759+ [tc-e (inclusive-range 0 10 ) (-lst -Byte)]
2760+ ;; Boundary conditions for inclusive-range
2761+ [tc-e (inclusive-range 5 5 ) (-lst -PosByte)] ; single element (start = end)
2762+ [tc-e (inclusive-range 0 0 ) (-lst -Byte)] ; single zero element
2763+ [tc-e (inclusive-range 0 255 ) (-lst -Byte)] ; full byte range
2764+ [tc-e (inclusive-range 1 1000 ) (-lst -PosIndex)] ; index range
2765+ [tc-e (inclusive-range 0 1000 ) (-lst -Index)] ; nonnegative index range
2766+ [tc-e (inclusive-range -5 5 ) (-lst -Int)] ; negative to positive
2767+ [tc-e (inclusive-range 1 10 3 ) (-lst -PosByte)] ; with step, positive
2768+ [tc-e (inclusive-range 10 1 -1 ) (-lst -PosByte)] ; descending range
2769+ [tc-e (inclusive-range 0.0 1.0 0.5 ) (-lst -Flonum)] ; flonum range
2770+ [tc-e (inclusive-range 1/2 5/2 1/2 ) (-lst -Rat)] ; rational range
2771+ [tc-e (inclusive-range 1 100 ) (-lst -PosByte)] ; max byte boundary
2772+ [tc-e (inclusive-range 1 256 ) (-lst -PosIndex)] ; beyond byte -> index
27572773
27582774 ;; test functions which do lookup with the "wrong type", where the
27592775 ;; result type shouldn't be widened to include that type
You can’t perform that action at this time.
0 commit comments