Skip to content

Conversation

@mmatera
Copy link
Contributor

@mmatera mmatera commented Jul 30, 2025

To explain the differences between return None and expression in an eval_ method.

To explain the differences between return `None` and `expression` in an  `eval_` method.
@rocky
Copy link
Member

rocky commented Jul 30, 2025

The information here is good, and your new idea using Pattern[] is good too.

We need to explain:

  • What return type None means.
  • How Mathics3 Options and the Python options dictionary work.
  • The subtitles of these, which are described here, and how this influences failure, and how the parameters influence pattern matching,
  • and lastly, pattern-matching ordering, which is currently undergoing revision. So, it is probably best to hold off on that.

However, I think these need to be separate, more advanced sections, after first completing simple cases.

So let's turn these into separate sections after going over more introductory stuff. I'd guess somewhere near "Working with Multiple Patterns"

We will need to go over the code base to add Pattern[] , but that will take some time. There is at least one of my new PR's that can benefit from this. I will revise that.

@mmatera
Copy link
Contributor Author

mmatera commented Jul 30, 2025

Ok..I left this here as a PR just for the record. When we arrive to a conclusion we can write the new section

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.

2 participants