kevinbirch/Djinn — Issue #7: Function Declarations are set the first time a function is called and do not change on subsequent calls.
Author: davidcourtney
Created: 2011-11-17 02:43:01+00:00
State: open

# Setup
In the following example I define a function dipinc that adds one to the second item in the stack.

\[dipinc drop 1 add top' \top' [id]]

## Expected
User> __10 20 dipinc__
stack: 11 20

User> __30 40 dipinc__
stack: 11 20 31 40

## Actual Result
User> __10 20 dipinc__
stack: 11 20

User> __30 40 dipinc__
stack: 11 20 31 20

The value of top' appears to be set to 20 on the first call and does not change on subsequent calls.