public inbox for ~johnnyrichard/olang-devel@lists.sr.ht
 help / color / mirror / code / Atom feed
From: ricardo_kagawa@disroot.org
To: ~johnnyrichard/olang-devel@lists.sr.ht
Cc: Ricardo Kagawa <ricardo_kagawa@disroot.org>
Subject: [PATCH 0/4] docs: spec: constant initialization and assignments
Date: Tue, 16 Apr 2024 17:17:09 -0300	[thread overview]
Message-ID: <20240416201713.24723-1-ricardo_kagawa@disroot.org> (raw)

From: Ricardo Kagawa <ricardo_kagawa@disroot.org>

For this patchset I'm assuming that:

- We agreed constants should be initialized immediately, and that this
  should be validated in syntax, rather than during semantic analysis;
- We agreed that chained assignments and related constructs were indeed
  not desired, and can be safely removed.

The last commit in the set is optional, and should be removed or
reverted depending on when the definitions of binary operators land. You
may choose to not include it regardless, but I'm not a great fan of
specifications that are not self-consistent.

-- >8 --

This patchset includes changes suggested in a superseded patchset:

- Refactoring and renaming non-terminals in the grammar specification
  for better clarity in definitions related to variable declarations
  and assignments;
- Removing the ability to declare uninitialized constant variables;
- Removing the ability to use assignments as expressions;
    - This also removes the ability to use chained assignments; and
    - This also removes the ability to use assignments inside
      conditional clauses of future statements.
- Temporarily removes assignment operators that still don't have their
  corresponding binary operators defined. Please remove or revert this
  last commit if those missing definitions are incorporated before this
  patchset. Otherwise, revert it after they are applied.

Ricardo Kagawa (4):
  docs: spec: refactor grammar specification
  docs: spec: immediate constant initialization
  docs: spec: remove assignment as expression
  docs: spec: postpone assignment operators

 docs/pages/language-specification.md | 36 +++++++++++-----------------
 1 file changed, 14 insertions(+), 22 deletions(-)

-- 
2.44.0


             reply	other threads:[~2024-04-16 20:17 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-16 20:17 ricardo_kagawa [this message]
2024-04-16 20:17 ` [PATCH 1/4] docs: spec: refactor grammar specification ricardo_kagawa
2024-04-16 22:32   ` Johnny Richard
2024-04-16 20:17 ` [PATCH 2/4] docs: spec: immediate constant initialization ricardo_kagawa
2024-04-16 22:33   ` Johnny Richard
2024-04-16 20:17 ` [PATCH 3/4] docs: spec: remove assignment as expression ricardo_kagawa
2024-04-16 22:34   ` Johnny Richard
2024-04-16 20:17 ` [PATCH 4/4] docs: spec: postpone assignment operators ricardo_kagawa
2024-04-16 22:35   ` Johnny Richard
2024-04-16 21:58 ` [PATCH 0/4] docs: spec: constant initialization and assignments Carlos Maniero

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240416201713.24723-1-ricardo_kagawa@disroot.org \
    --to=ricardo_kagawa@disroot.org \
    --cc=~johnnyrichard/olang-devel@lists.sr.ht \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.johnnyrichard.com/olang.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox