Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Added support for subs attribute #2695

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

Merged
merged 1 commit into from
May 10, 2024
Merged

Added support for subs attribute #2695

merged 1 commit into from
May 10, 2024

Conversation

anutosh491
Copy link
Collaborator

This allows us to address the following case

from lpython import S
from sympy import Symbol, sin

def main0():
    x: S = Symbol('x')
    y: S = Symbol('y')
    z: S = sin(x)
    s: S = z.subs(x, y)
    print(s)

main0()
(lf) anutosh491@spbhat68:~/lpython/lpython$ lpython --enable-symengine examples/expr2.py 
sin(y)
(lf) anutosh491@spbhat68:~/lpython/lpython$ lpython --enable-symengine examples/expr2.py --backend=c
sin(y)

@anutosh491 anutosh491 mentioned this pull request May 10, 2024
Copy link
Contributor

@certik certik left a comment

Choose a reason for hiding this comment

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

I think that this is fine. Thanks!

@certik certik merged commit 2ad3c4d into lcompilers:main May 10, 2024
14 checks passed
@anutosh491 anutosh491 deleted the subs branch June 13, 2024 12:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants