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

toExpression doesn't work properly for some operators #14

Open
leonid-shutov opened this issue Dec 15, 2024 · 0 comments
Open

toExpression doesn't work properly for some operators #14

leonid-shutov opened this issue Dec 15, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@leonid-shutov
Copy link

Describe the bug
toExpression doesn't work properly for some operators

To Reproduce

const program = '(eq 1 2)';

const tokens = tokenize(program);

const expression = parse(tokens);

console.log(expression.toExpression()); // (1eq2)

console.log(expression.toJavaScript()); // () => (1eq2)

Expected behavior
expression.toExpression() has to return 1 === 2

Additional context
We probably have to create a mapping between lisp and javascript operators

@leonid-shutov leonid-shutov added the bug Something isn't working label Dec 15, 2024
@leonid-shutov leonid-shutov mentioned this issue Dec 15, 2024
5 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant