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

Is macro incompatible with Pluto? #585

Closed
AnselmJeong opened this issue Oct 18, 2020 · 2 comments
Closed

Is macro incompatible with Pluto? #585

AnselmJeong opened this issue Oct 18, 2020 · 2 comments

Comments

@AnselmJeong
Copy link

I cannot quite fully understand the encapsulation of each cell in Pluto. Due to this complication, very simple macro does not work properly.

image

Above is a very simple macro modifying the input expression (in this scenario, a variable)

In the second cell, the variable c could be modified without any problem.

However, in a newer cell, this macro does not work like this.

image

May be, a variable defined in a certain cell cannot be modified by a macro even though the variable has been escaped with esc() in the macro definition.

By the way, this macro works without any problem in Jupyter Notebook.

Thanks.

@fonsp
Copy link
Owner

fonsp commented Oct 18, 2020

Have a look here: #196

@fonsp fonsp closed this as completed Oct 18, 2020
@mcabbott
Copy link
Contributor

mcabbott commented Oct 20, 2020

Note that c += 2 when c is defined in another cell is already a problem. Even if Pluto could see inside what the macro does, it wouldn't like it:

Screenshot 2020-10-20 at 11 42 57

`

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

No branches or pull requests

3 participants