From 6036ca2d7e45f61427eea96b38b77db867d8d4c4 Mon Sep 17 00:00:00 2001 From: Lukas Wirth Date: Fri, 5 Jul 2024 17:29:50 +0200 Subject: [PATCH 1/4] Add library crate definition back --- src/changelog.rst | 1 - src/glossary.rst | 8 ++++++++ src/program-structure-and-compilation.rst | 3 +++ 3 files changed, 11 insertions(+), 1 deletion(-) diff --git a/src/changelog.rst b/src/changelog.rst index dcc84327..e75a0737 100644 --- a/src/changelog.rst +++ b/src/changelog.rst @@ -74,7 +74,6 @@ Language changes in Rust 1.79.0 * Updated glossary entries: :t:`binary crate`, :t:`proc-macro crate` * Updated paragraphs: :p:`fls_9ub6ks8qrang`, :p:`fls_Mf62VqAhoZ3c` * Moved paragraph: :p:`fls_sbGnkm8Ephiu` - * Removed paragraph about library crates * `Check return types of function types for well-formedness `_ diff --git a/src/glossary.rst b/src/glossary.rst index c355290c..099a3409 100644 --- a/src/glossary.rst +++ b/src/glossary.rst @@ -3744,6 +3744,14 @@ lexical element A :dt:`lexical element` is the most basic syntactic element in program text. +.. _fls_r1sk7vdgckym: + +library crate +^^^^^^^^^^^^^ + +:dp:`fls_3m8lg4mdc2x0` +A :dt:`library crate` is a :t:`crate` that is not a :t:`binary crate`. + .. _fls_vdhaa61g6kah: lifetime diff --git a/src/program-structure-and-compilation.rst b/src/program-structure-and-compilation.rst index adbc6353..1f771808 100644 --- a/src/program-structure-and-compilation.rst +++ b/src/program-structure-and-compilation.rst @@ -138,6 +138,9 @@ The :t:`function` in scope of a :t:`binary crate`'s :t:`crate root module` under the :t:`name` ``main`` with a :t:`main function signature` is the :t:`binary crate`'s :t:`program entry point`. +:dp:`fls_d9nn4yuiw1ja` +A :t:`library crate` is a :t:`crate` that is not a :t:`binary crate`. + :dp:`fls_Mf62VqAhoZ3c` A :t:`proc-macro crate` is a :t:`crate` whose :t:`crate type` is ``proc-macro``. From 904b5c76d21a7fda726ac6201b184d4d6e75f77d Mon Sep 17 00:00:00 2001 From: Lukas Wirth Date: Mon, 8 Jul 2024 10:18:32 +0200 Subject: [PATCH 2/4] Be explicit with what a library crate entails --- src/glossary.rst | 3 ++- src/program-structure-and-compilation.rst | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/glossary.rst b/src/glossary.rst index 099a3409..a0c85ede 100644 --- a/src/glossary.rst +++ b/src/glossary.rst @@ -3750,7 +3750,8 @@ library crate ^^^^^^^^^^^^^ :dp:`fls_3m8lg4mdc2x0` -A :dt:`library crate` is a :t:`crate` that is not a :t:`binary crate`. +A :dt:`library crate` is a :t:`crate` whose :t:`crate type` is ``lib``, ``rlib``, +``staticlib``, ``dylib``, or ``cdylib``. .. _fls_vdhaa61g6kah: diff --git a/src/program-structure-and-compilation.rst b/src/program-structure-and-compilation.rst index 1f771808..e8ef612b 100644 --- a/src/program-structure-and-compilation.rst +++ b/src/program-structure-and-compilation.rst @@ -139,7 +139,8 @@ the :t:`name` ``main`` with a :t:`main function signature` is the :t:`binary crate`'s :t:`program entry point`. :dp:`fls_d9nn4yuiw1ja` -A :t:`library crate` is a :t:`crate` that is not a :t:`binary crate`. +A :t:`library crate` is a :t:`crate` whose :t:`crate type` is ``lib``, ``rlib``, +``staticlib``, ``dylib``, or ``cdylib``. :dp:`fls_Mf62VqAhoZ3c` A :t:`proc-macro crate` is a :t:`crate` whose :t:`crate type` is ``proc-macro``. From 8a88c86e2ed3e6d03ea53e07db3dccd1c1424965 Mon Sep 17 00:00:00 2001 From: Lukas Wirth Date: Mon, 8 Jul 2024 10:40:17 +0200 Subject: [PATCH 3/4] Update changelog --- src/changelog.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/changelog.rst b/src/changelog.rst index e75a0737..8b27eaee 100644 --- a/src/changelog.rst +++ b/src/changelog.rst @@ -72,7 +72,7 @@ Language changes in Rust 1.79.0 * New glossary entry: :t:`crate type` * New paragraphs: :p:`fls_unxalgMqIr3v`, :p:`fls_e7jGvXvTsFpC`, :p:`fls_kQiJPwb2Hjcc`, :p:`fls_OyFwBtDGVimT` * Updated glossary entries: :t:`binary crate`, :t:`proc-macro crate` - * Updated paragraphs: :p:`fls_9ub6ks8qrang`, :p:`fls_Mf62VqAhoZ3c` + * Updated paragraphs: :p:`fls_9ub6ks8qrang`, :p:`fls_Mf62VqAhoZ3c`, :p:`fls_d9nn4yuiw1ja`, :p:`fls_3m8lg4mdc2x0` * Moved paragraph: :p:`fls_sbGnkm8Ephiu` * `Check return types of function types for well-formedness `_ From 4d08044080a3e36876d693986374a7980bfd310a Mon Sep 17 00:00:00 2001 From: Pietro Albini Date: Mon, 8 Jul 2024 11:03:14 +0200 Subject: [PATCH 4/4] Apply suggestions from code review --- src/changelog.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/changelog.rst b/src/changelog.rst index 8b27eaee..5124d3e2 100644 --- a/src/changelog.rst +++ b/src/changelog.rst @@ -71,8 +71,8 @@ Language changes in Rust 1.79.0 * New section: :ref:`fls_8JB3SJqamdpU` * New glossary entry: :t:`crate type` * New paragraphs: :p:`fls_unxalgMqIr3v`, :p:`fls_e7jGvXvTsFpC`, :p:`fls_kQiJPwb2Hjcc`, :p:`fls_OyFwBtDGVimT` - * Updated glossary entries: :t:`binary crate`, :t:`proc-macro crate` - * Updated paragraphs: :p:`fls_9ub6ks8qrang`, :p:`fls_Mf62VqAhoZ3c`, :p:`fls_d9nn4yuiw1ja`, :p:`fls_3m8lg4mdc2x0` + * Updated glossary entries: :t:`binary crate`, :t:`library crate`, :t:`proc-macro crate` + * Updated paragraphs: :p:`fls_9ub6ks8qrang`, :p:`fls_Mf62VqAhoZ3c`, :p:`fls_d9nn4yuiw1ja` * Moved paragraph: :p:`fls_sbGnkm8Ephiu` * `Check return types of function types for well-formedness `_