This PR implements the changes proposed in https://github.com/Mathics3/mathics-core/discussions/317#discussioncomment-2865937