[Chapel Merge] Add documentation for language-supplied == and != on unions

Branch: refs/heads/main
Revision: abb5257919418d4554556bba42986f5cbb60ebd5
Author: bradcray
Link: Add documentation for language-supplied == and != on unions by bradcray · Pull Request #28957 · chapel-lang/chapel · GitHub
Log Message:
Add documentation for language-supplied == and != on unions (#28957)

[reviewed by @DanilaFe]

This belatedly adds a description to the language spec of the
Chapel-supplied == and != operators on unions, as added in #14139 .

While here, I reordered and changed the level of a few sections in this
chapter to match the records chapter, which I believe has received more
attention in recent years. Specifically, I moved the bit about declaring
union types ahead of the section about referring to union types (since
one must exist before you can name it, and naming it is strictly less
interesting) and wordsmithed both. I also moved assignment and these
newly added comparisons into a "Common Operations" section to match the
approach in records.

Compare: Comparing 215161fa6e9309c8c8515595b1c1a78d3e3b0d2f...cb5106538cf13b33269d345cbbe82b053f5a5089 · chapel-lang/chapel · GitHub

Diff:
M doc/rst/language/spec/unions.rst
https://github.com/chapel-lang/chapel/pull/28957.diff