+httpVersionP = string "HTTP/"
+ >>
+ -- 頻出するので高速化
+ choice [ string "1.0" >> return (HttpVersion 1 0)
+ , string "1.1" >> return (HttpVersion 1 1)
+ -- 一般の場合
+ , do major <- many1 digit
+ _ <- char '.'
+ minor <- many1 digit
+ return $ HttpVersion (read major) (read minor)
+ ]
+