Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exposed some query methods #1981

Closed

Conversation

anutosh491
Copy link
Contributor

No description provided.

Copy link
Member

@isuruf isuruf left a comment

Choose a reason for hiding this comment

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

Why do we need these methods and just 5 of them?
It's a simple one liner basic_get_type(s) == SYMENGINE_ADD.

@certik
Copy link
Contributor

certik commented Oct 3, 2023

I agree, I think basic_get_type(s) == SYMENGINE_ADD seems good enough to me.

@certik certik closed this Oct 3, 2023
@anutosh491
Copy link
Contributor Author

I think so here we would only need the basic_is_Exp function because I don't we have something like
basic_get_type(s) == SYMENGINE_EXP
The type of s would still be Pow, we would just need to check it's base against E

@certik
Copy link
Contributor

certik commented Oct 3, 2023

Why couldn't we do basic_get_type(s) == SYMENGINE_EXP in LPython?

@anutosh491
Copy link
Contributor Author

Because I don't think we have a defined SYMENGINE_EXP class type registered here (https://github.com/symengine/symengine/blob/master/symengine/type_codes.inc)

@certik
Copy link
Contributor

certik commented Oct 3, 2023

EXP I think is represented as just Power with a base E.

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.

None yet

3 participants