Skip to content

add factorial and modulo and fix .gitignore#2

Open
aoieop wants to merge 7 commits intopatrickjonesuk:masterfrom
aoieop:master
Open

add factorial and modulo and fix .gitignore#2
aoieop wants to merge 7 commits intopatrickjonesuk:masterfrom
aoieop:master

Conversation

@aoieop
Copy link
Copy Markdown

@aoieop aoieop commented Apr 6, 2021

No description provided.

Copy link
Copy Markdown
Owner

@patrickjonesuk patrickjonesuk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please fix these errors so that I can test this.

Comment thread mathterpreter/_parser.py
return result

def _multiplication_division(self):
def _multiplication_division_modulo(self):
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You have renamed this function but not renamed its usages.

Comment thread mathterpreter/_parser.py Outdated
result = RootNode(result, self._literal_polarity())
elif self._token.type == TokenType.FACTORIAL_OPERATOR:
self._iterate_token()
result = RootNode(result, self._literal_polarity)
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

RootNode?

Comment thread mathterpreter/_parser.py Outdated
result = RootNode(result, self._literal_polarity())
elif self._token.type == TokenType.FACTORIAL_OPERATOR:
self._iterate_token()
result = RootNode(result, self._literal_polarity)
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You need to call the function, not reference it

@patrickjonesuk patrickjonesuk added the enhancement New feature or request label Apr 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants