package iso639
All checked builds passInstall
dune-project
Dependency
Authors
Maintainers
Sources
sha256=6056e5da2f82fa775fb637008219b0825cc48b41a3df902f79036a5e2a1a7385
sha512=aa5e91457289035f8369fdbaf138e271a45ebf0458729cd4afbe662c133776c63d025704abee0ed48790a6d90fdcb6e368d7f9088dd78bf774480d55f80a514d
Description
This library implements a type to identify languages and macrolanguages from ISO 639-3 and language groups from ISO 639-5, and provides conversions to and from two- and three-letter codes defined by these and other parts of ISO 639.
Added to opam-repository:
README
Identification of Languages and Language Groups for OCaml
Synopsis
This library defines abstract types for languages and language families covered by ISO 639 and provides related functionality and conversions.
Lang.tmaps one-to-one to ISO 639-3 language codes, which covers individual languages and macrolanguages.Lang_family.tmaps one-to-one to ISO 639-5 language codes, which covers language families and groups.Lang_or_family.tis the sum of the two above types.
Example
# #require "iso639";;
# open Iso639;;
# #install_printer Lang.pp;;
# let por = Lang.of_string_exn "por";;
val por : Lang.t = por
# Lang.to_iso639p1 por;;
- : string option = Some "pt"
# Lang.macrolanguage por;;
- : Lang.t option = None
# Lang.macrolanguage_members por;;
- : Lang.t list = []
# let nor = Lang.of_string_exn "nor";;
val nor : Lang.t = nor
# Lang.macrolanguage_members nor;;
- : Lang.t list = [nob; nno]
# Lang.macrolanguage (Lang.of_string_exn "nob");;
- : Lang.t option = Some norLimitations
Only part of ISO 639 which are expected to be commonly used by applications are implemented.
The library does not include the English end French names of languages, and there is no plan to add them, as this would significantly increase the size of the library.
Dev Dependencies
None
Optional Dependencies
None
Used by (1)
Conflicts
None
Build status
Results of building iso639 with each compiler on check.ci.ocaml.org, run of against opam-repository 8a77e58. All results for this package.
Each result links to its build log. To keep crawlers from overloading the site, build logs require a GitHub sign-in (see ocurrent/opam-health-check). On your first log, GitHub asks you to “Authorize opam-health-check”, the OCurrent app that runs these checks; it sees only your public profile, not your repositories. The sign-in lasts 30 days.
| Version | OCaml 4.11 | OCaml 4.14 | OCaml 5.2 | OCaml 5.4 | OCaml 5.5 |
|---|---|---|---|---|---|
| 0.0.5 (this version) | good | good | good | good | good |
- good Package successfully built
- partial One of the dependencies failed to build
- bad Package failed to build
- n/a Package is not available in this environment
- internal Internal failure