Skip to content

Add Release, the obsolete form of Evaluate - #1998

Merged
rocky merged 2 commits into
Mathics3:masterfrom
tombouctou:add-obsolete-release
Oct 16, 2026
Merged

rocky merged 2 commits into
Mathics3:masterfrom
tombouctou:add-obsolete-release

Conversation

@tombouctou

Copy link
Copy Markdown
Collaborator

Release is the pre-Version 2.0 name of Evaluate. WMA still knows the symbol (its reference page marks it as obsolete, superseded by Evaluate and ReleaseHold), and older packages use it, for instance to build the left-hand side of a definition from a variable:

DeclareFamily[name_, ...] := Module[{...},
  Format[Release[name][k_]] := Subscript[name, k];
  ...]

In Mathics3 Release is undefined, so such definitions are stored for Release[h] instead of h.

This PR adds Release as a builtin that evaluates to its argument, with a doctest, a SYMBOLS_MANIFEST.txt entry and tests in test/builtin/test_evaluation.py. Unlike Evaluate, it does not pierce Hold attributes.

🤖 Generated with Claude Code

Release was superseded by Evaluate and ReleaseHold in Version 2.0, but
WMA still knows it, and old packages use it, for instance to build the
left-hand side of a definition from a variable:
Format[Release[name][k_]] := Subscript[name, k]. Here it simply
evaluates to its argument.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Comment thread mathics/builtin/evaluation.py
@mmatera

mmatera commented Oct 16, 2026

Copy link
Copy Markdown
Contributor

LGTM

@rocky

rocky commented Oct 16, 2026

Copy link
Copy Markdown
Member

As @mmatera says: LGTM

@rocky
rocky merged commit e60bc7b into Mathics3:master Oct 16, 2026
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants