Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update changelog for 1.80.0 #521

Merged
merged 5 commits into from
Sep 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions src/changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,31 @@ with the change that has been applied due to it.
just the language changes that had an impact to the FLS. See the `release
notes`_ for a full list of changes.

Language changes in Rust 1.80.0
-------------------------------

* `Document maximum allocation size <https://github.com/rust-lang/rust/pull/116675/>`_

* New paragraphs: :p:`fls_CUJyMj0Sj8NS`, :p:`fls_kaomYy0Ml4Nh`, :p:`fls_B5cmkWfD5GNt`, :p:`fls_oqhQ62mDLckN`, :p:`fls_uhwpuv6cx4ip`, :p:`fls_xuuFKmm181bs`

* `Allow zero-byte offsets and ZST read/writes on arbitrary pointers <https://github.com/rust-lang/rust/pull/117329/>`_

* No change: this previous restriction is not specified in the FLS

* `Support C23's variadics without a named parameter <https://github.com/rust-lang/rust/pull/124048/>`_

* No change: this previous restriction is not specified in the FLS

* `Stabilize `exclusive_range_pattern` feature <https://github.com/rust-lang/rust/pull/124459/>`_

* Changed syntax: :s:`RangePattern`

* New syntax: :s:`ExclusiveRangePattern`

* Changed paragraph: :p:`fls_8Q6NfRx4j5V7`

* New paragraphs: :p:`fls_3PyquOKjA7SI`, :p:`fls_8bdOqkO1NuJW`, :p:`fls_EDL1Pi56KQ2H`

Language changes in Rust 1.79.0
-------------------------------

Expand Down
28 changes: 23 additions & 5 deletions src/patterns.rst
Original file line number Diff line number Diff line change
Expand Up @@ -433,6 +433,7 @@ Range Patterns
RangePattern ::=
HalfOpenRangePattern
| InclusiveRangePattern
| ExclusiveRangePattern
| ObsoleteRangePattern

HalfOpenRangePattern ::=
Expand All @@ -441,6 +442,9 @@ Range Patterns
InclusiveRangePattern ::=
RangePatternLowBound $$..=$$ RangePatternHighBound

ExclusiveRangePattern ::=
RangePatternLowBound $$..$$ RangePatternHighBound

ObsoleteRangePattern ::=
RangePatternLowBound $$...$$ RangePatternHighBound

Expand Down Expand Up @@ -471,6 +475,10 @@ A :t:`half-open range pattern` is a :t:`range pattern` with only a
An :t:`inclusive range pattern` is a :t:`range pattern` with both a
:t:`range pattern low bound` and a :t:`range pattern high bound`.

:dp:`fls_3PyquOKjA7SI`
An :t:`exclusive range pattern` is a :t:`range pattern` with both a
:t:`range pattern low bound` and a :t:`range pattern high bound`.

:dp:`fls_akf9x5r6e0ta`
An :t:`obsolete range pattern` is a :t:`range pattern` that uses obsolete syntax
to express an :t:`inclusive range pattern`.
Expand All @@ -494,6 +502,10 @@ when the context is a :t:`slice pattern`.
The :t:`range pattern low bound` of an :t:`inclusive range pattern` shall be
less than or equal to its :t:`range pattern high bound`.

:dp:`fls_8bdOqkO1NuJW`
The :t:`range pattern low bound` of an :t:`exclusive range pattern` shall be
less than to its :t:`range pattern high bound`.

:dp:`fls_s2b5n4snc4d7`
An :t:`obsolete range pattern` is equivalent to an :t:`inclusive range pattern`.

Expand All @@ -508,11 +520,11 @@ The :t:`[type]s` of the :t:`range pattern low bound` and the
:dp:`fls_3js1645tgh31`
The :t:`type` of a :t:`range pattern` is determined as follows:

* :dp:`fls_wfqrbwrogjnq`
If the :t:`range pattern` is expressed as an :t:`inclusive range pattern` or
an :t:`obsolete range pattern`, then the :t:`type` is the :t:`unified type` of
the :t:`[type]s` of the :t:`range pattern low bound` and the
:t:`range pattern high bound`.
* :dp:`fls_8Q6NfRx4j5V7`
If the :t:`range pattern` is expressed as an :t:`inclusive range pattern`, an
:t:`exclusive range pattern`, or an :t:`obsolete range pattern`, then the
:t:`type` is the :t:`unified type` of the :t:`[type]s` of the
:t:`range pattern low bound` and the :t:`range pattern high bound`.

* :dp:`fls_rgr7t33s0m7m`
Otherwise the :t:`type` is the :t:`type` of the :t:`range pattern low bound`.
Expand Down Expand Up @@ -1423,6 +1435,12 @@ Range Pattern Matching
the inclusive range from the :t:`range pattern low bound` to the
:t:`range pattern high bound`, then matching succeeds.

#. :dp:`fls_EDL1Pi56KQ2H`
If the :t:`range pattern` is expressed as an :t:`exclusive range pattern`
and the context :t:`value` is in the exclusive range from the
:t:`range pattern low bound` to the :t:`range pattern high bound`, then
matching succeeds.

#. :dp:`fls_n4t3xah1pk7i`
Otherwise matching fails.

Expand Down
25 changes: 25 additions & 0 deletions src/values.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,17 @@ Values
A :t:`value` is either a :t:`literal` or the result of a computation, that may
be stored in a memory location, and interpreted based on some :t:`type`.

:dp:`fls_CUJyMj0Sj8NS`
An :dt:`allocated object` is a :t:`value` stored at some memory address.

:dp:`fls_kaomYy0Ml4Nh`
An :t:`[allocated object]s` :dt:`base address` is the the memory address the
object is stored.

:dp:`fls_B5cmkWfD5GNt`
An :t:`[allocated object]s` :dt:`memory size` is the number of bytes the object
spans in memory from its :t:`base address`.

:dp:`fls_rixdyyc525xp`
Two :t:`[value]s` :t:`overlap` when

Expand All @@ -37,6 +48,20 @@ Two :t:`[value]s` :t:`overlap` when
It is undefined behavior to create a :t:`value` from uninitialized memory unless
the :t:`type` of the :t:`value` is a :t:`union type`.

:dp:`fls_oqhQ62mDLckN`
It is undefined behavior to create an :t:`allocated object` at :t:`base address`
:c:`null`.

:dp:`fls_uhwpuv6cx4ip`
It is undefined behavior to create an :t:`allocated object` with :t:`memory
size` ``size`` at a :t:`base address` ``base`` where ``base + size`` is greater
than the architectures maximum :c:`usize` value.

:dp:`fls_xuuFKmm181bs`
It is undefined behavior to create an :t:`allocated object` with :t:`memory
size` ``size`` where ``size`` is greater than the architectures maximum
:c:`isize` value.
Comment on lines +51 to +63
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be in an undefined behavior rubric, so that it shows up in the UB appendix.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It already is (see line 45)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Whoops!


.. _fls_ixjc5jaamx84:

Constants
Expand Down
Loading