12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182(**************************************************************************)(* *)(* Copyright 2018-2023 OCamlPro *)(* *)(* All rights reserved. This file is distributed under the terms of the *)(* GNU Lesser General Public License version 2.1, with the special *)(* exception on linking described in the file LICENSE. *)(* *)(**************************************************************************)openMap.Make(Int)letcodes=empty|>add100"Continue"|>add101"Switching Protocols"|>add102"Processing"|>add103"Early Hints"|>add200"OK"|>add201"Created"|>add202"Accepted"|>add203"Non-Authoritative Information"|>add204"No Content"|>add205"Reset Content"|>add206"Partial Content"|>add207"Multi-Status"|>add208"Already Reported"|>add226"IM Used"|>add300"Multiple Choices"|>add301"Moved Permanently"|>add302"Found"|>add303"See Other"|>add304"Not Modified"|>add305"Use Proxy"|>add306"Switch Proxy"|>add307"Temporary Redirect"|>add308"Permanent Redirect"|>add400"Bad Request"|>add401"Unauthorized"|>add402"Payment Required"|>add403"Forbidden"|>add404"Not Found"|>add405"Method Not Allowed"|>add406"Not Acceptable"|>add407"Proxy Authentication Required"|>add408"Request Timeout"|>add409"Conflict"|>add410"Gone"|>add411"Length Required"|>add412"Precondition Failed"|>add413"Payload Too Large"|>add414"URI Too Long"|>add415"Unsupported Media Type"|>add416"Range Not Satisfiable"|>add417"Expectation Failed"|>add418"I'm a teapot"|>add421"Misdirected Request"|>add422"Unprocessable Entity"|>add423"Locked"|>add424"Failed Dependency"|>add425"Too Early"|>add426"Upgrade Required"|>add428"Precondition Required"|>add429"Too Many Requests"|>add431"Request Header Fields Too Large"|>add451"Unavailable For Legal Reasons"|>add500"Internal Server Error"|>add501"Not Implemented"|>add502"Bad Gateway"|>add503"Service Unavailable"|>add504"Gateway Timeout"|>add505"HTTP Version Not Supported"|>add506"Variant Also Negotiates"|>add507"Insufficient Storage"|>add508"Loop Detected"|>add510"Not Extended"|>add511"Network Authentication Required"leterrorcode=find_optcodecodesletcodes=fold(funcodeerracc->matchaccwith|None->iferr=sthenSomecodeelseNone|Somec->Somec)codesNone