TOML Fortran Bibliothek#
Dieses Projekt stellt eine Bibliothek um mit TOML Dokumenten zu arbeiten, Datenstrukturen zu definieren und diese mit Fortran zu serialisieren und zu deserialisieren. Derzeit wird der TOML Standard in Version 1.0.0 unterstützt. Das TOML Fortran Projekt ist auf GitHub unter toml-f/toml-f gehostet.
Tutorials
Anleitungen und Kurse zur Verwendung von TOML mit kompletten und eigenständigen Beispielen.
Rezepte
Beispiele und Rezepte für die häufigsten Aufgaben mit TOML Fortran.
Referenz
Dokumentation aller Prozeduren und abgeleiteten Typen.
Installation
Anleitungen zur Installation, Aktualisierung oder Kompilierung von TOML Fortran.
Repository
GitHub Repository für die Entwicklung von TOML Fortran.
Extern
Externe Links zu anderen Ressourcen, Blogs, etc.
News
05 March - TOML Fortran 0.5.0 released
Support for TOML 1.1.0 is here! With this release TOML Fortran introduces full support for the new TOML release, which adds support for newlines and trailing commas to inline tables, new escape sequences, and extends the datetime format with making seconds optional.
03 December - TOML Fortran 0.4.2 released
Maintenance and bugfix release to address issues found for GFortran on MacOS/ppc32 and Cray compilers. Furthermore, parsing the header of an array of tables with whitespace and the tokenization of multiline strings with escape characters was fixed.
01 April - TOML Fortran 0.4.0 released
This release refactors the internal access of the storage structures to allow more efficient operations like deletion or renaming. Additionally, the serialization functionality has been reworked to allow writing to files, units or strings using similar interfaces.
03 August - Jonquil: Bringing TOML blooms to JSON land
Jonquil started out of the idea to make a TOML parser speak JSON. First explored as a way to connect to the toml-test validation suite, the implementation was brief and expressive enough to be explored as a tutorial. Since the implementation was taken serious enough to enter into JSON Fortran’s benchmarks and turned out to actually be competitive with JSON Fortran, revisiting the idea of a JSON parser in TOML Fortran was warranted.
01 August - TOML Fortran 0.3.0 released
This release comes with a new backend for the deserialization of TOML documents, making the parser more robust against unclosed inline tables and arrays. Furthermore, a context can now be captured which allows reporting messages like errors as annotations in TOML document, making both the default errors produced by the parsers more useful and also enabling users of TOML Fortran to create consistently formatted reports. Together with the refactoring of the internal representation for storing TOML values, the low-level interface to TOML values becomes more consistent and easier to use. A long-standing issue with supporting Unicode escape sequences in strings has been resolved and TOML Fortran now fully supports all TOML 1.0.0 escape sequences.
Users
TOML Fortran wird zum Beispiel in dem Fortran Paketmanager (fpm) verwendet, ein typisches Paketmanifest in TOML wird unten angezeigt
name = "toml-f"
version = "0.5.0"
license = "Apache-2.0 OR MIT"
maintainer = ["@awvwgk"]
author = ["Sebastian Ehlert"]
copyright = "2019-2026 Sebastian Ehlert"
homepage = "https://toml-f.readthedocs.org"
keywords = ["toml", "io", "serde"]
description = "TOML parser implementation for data serialization and deserialization"
[library]
source-dir = "src"
[build]
auto-tests = false
[[test]]
name = "tftest"
source-dir = "test/unit"
[test.dependencies]
test-drive.git = "https://github.com/fortran-lang/test-drive.git"
[[executable]]
name = "toml2json"
source-dir = "test/compliance"
main = "toml2json.f90"
[[executable]]
name = "json2toml"
source-dir = "test/compliance"
main = "json2toml.f90"
# FORD documentation settings
[extra.ford]
project = "TOML-Fortran"
summary = "TOML parser implementation for data serialization and deserialization in Fortran."
favicon = "./assets/toml-f-64x64.png"
project_github = "https://github.com/toml-f/toml-f"
project_download = "https://github.com/toml-f/toml-f/releases"
project_website = "https://toml-f.readthedocs.io"
author = "Sebastian Ehlert"
github = "https://github.com/awvwgk"
src_dir = ["./src"]
exclude_dir = ["./test"]
media_dir = "./assets"
docmark = "<"
predocmark = ">"
source = true
graph = true
sort = "alpha"
print_creation_date = true
creation_date = "%Y-%m-%d %H:%M %z"
md_extensions = ["markdown.extensions.toc", "markdown.extensions.smarty"]
externalize = true
[extra.ford.extra_mods]
iso_fortran_env = "https://gcc.gnu.org/onlinedocs/gfortran/ISO_005fFORTRAN_005fENV.html"
A collection of projects using TOML Fortran is shown below:
Your project is using TOML Fortran but not listed here? Let us know of your work by opening a discussion on GitHub or create a pull request to add it to the selection above.