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

Clone_Function and the frame reference problem #2044

Open
rebolbot opened this issue Aug 5, 2013 · 2 comments
Open

Clone_Function and the frame reference problem #2044

rebolbot opened this issue Aug 5, 2013 · 2 comments

Comments

@rebolbot
Copy link
Collaborator

rebolbot commented Aug 5, 2013

Submitted by: Ladislav

In the c-function.c file there is a Clone_Function function used when objects are cloned. Clone_Function creates a new function sharing both the spec and args values with the original func argument. This makes any of the spec and args values unsuitable to identify the function. Ticket #2025 demonstrates that the body value cannot identify the function either. R3 function values consist only of spec args and body values. Thus, there is nothing left to use as the frame reference value needed for function variables to identify the function to which they belong.

The solution proposed:

In my opinion, the best solution of the function frame reference problem in R3 is to adjust the Clone_Function implementation to copy the args value of the original func argument to make sure the args value identifies the function to which it belongs and to use the args value as the frame reference of function-local variables.

CC - Data [ Version: r3 master Type: Bug Platform: All Category: Datatype Reproduce: Always Fixed-in:none ]

@rebolbot
Copy link
Collaborator Author

rebolbot commented Aug 5, 2013

Submitted by: Ladislav

In the core-tests suite.

@rebolbot
Copy link
Collaborator Author

rebolbot commented Aug 5, 2013

Submitted by: Ladislav

Fixed by rebol/rebol#122

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant