random_int() return type and parameters rule by cs278 · Pull Request #99 · phpstan/phpstan-src

Also, you should look into the level 7 stuff with reportMaybe I suggested in the first review. Otherwise it's mergeable!

Yeah not entirely sure what should be considered a "maybe", if the max argument could be less than the min argument should that be a maybe? e.g. 0, int<-1,1> and int<-5,5>, int<0,10> are maybes, but 0, int<-10,-5> and int<10,20>, int<0,5> are always errors?