From 89710bf8a1914e22fe61e4e087f5ff5e97a32f02 Mon Sep 17 00:00:00 2001 From: jam-khan Date: Mon, 15 Jan 2024 15:32:31 -0500 Subject: [PATCH] Add docstring for TOML stdlib module (#52834) --- base/docs/temp.cpp | 0 base/toml_parser.jl | 5 +++++ stdlib/TOML/src/TOML.jl | 5 +++++ stdlib/TOML/test/runtests.jl | 4 +--- 4 files changed, 11 insertions(+), 3 deletions(-) create mode 100644 base/docs/temp.cpp diff --git a/base/docs/temp.cpp b/base/docs/temp.cpp new file mode 100644 index 0000000000000..e69de29bb2d1d diff --git a/base/toml_parser.jl b/base/toml_parser.jl index 086b7d99580c0..eb7ffda2f5940 100644 --- a/base/toml_parser.jl +++ b/base/toml_parser.jl @@ -1,5 +1,10 @@ # This file is a part of Julia. License is MIT: https://julialang.org/license +""" +`Base.TOML` is an undocumented internal part of Julia's TOML parser +implementation. Users should call the the documented interface in the +TOML.jl standard library instead (by `import TOML` or `using TOML`). +""" module TOML using Base: IdSet diff --git a/stdlib/TOML/src/TOML.jl b/stdlib/TOML/src/TOML.jl index a2ea1869b4079..a94eb926f8b88 100644 --- a/stdlib/TOML/src/TOML.jl +++ b/stdlib/TOML/src/TOML.jl @@ -1,5 +1,10 @@ # This file is a part of Julia. License is MIT: https://julialang.org/license +""" +TOML.jl is a Julia standard library for parsing and writing TOML v1.0 files. +This module provides functions to parse TOML strings and files into Julia data structures +and to serialize Julia data structures to TOML format. +""" module TOML module Internals diff --git a/stdlib/TOML/test/runtests.jl b/stdlib/TOML/test/runtests.jl index e471068f36e7f..47c762d054711 100644 --- a/stdlib/TOML/test/runtests.jl +++ b/stdlib/TOML/test/runtests.jl @@ -27,7 +27,5 @@ include("parse.jl") @inferred TOML.parse("foo = 3") @testset "Docstrings" begin - undoc = Docs.undocumented_names(TOML) - @test_broken isempty(undoc) - @test undoc == [:TOML] + @test isempty(Docs.undocumented_names(TOML)) end