 |
Tech GURU

Joined: 18 Oct 2000 Posts: 2733 Location: Atlanta, USA
|
Posted: Sat Nov 22, 2008 6:09 am
[2.37] Can't call function with a function |
While working on a forum request I came across this oddity.
| Code: |
| #noop %pop(%push("test",test)) |
I can't seem to call a function with a function. Everything works well as two separate calls. The inner function called is highlighted green which suggests it's not parsing properly. Of course I could be missing something obvious, but I didn't think this was a CMUD restriction. |
|
_________________ Asati di tempari! |
|
|
 |
Tarn GURU
Joined: 10 Oct 2000 Posts: 875 Location: USA
|
Posted: Sat Nov 22, 2008 8:09 am Re: [2.37] Can't call function with a function |
| Tech wrote: |
While working on a forum request I came across this oddity.
| Code: |
| #noop %pop(%push("test",test)) |
I can't seem to call a function with a function. Everything works well as two separate calls. The inner function called is highlighted green which suggests it's not parsing properly. Of course I could be missing something obvious, but I didn't think this was a CMUD restriction. |
I'm not sure I understand what you're trying to do. %push takes the string to add and the contents of the list as arguments while %pop takes the name of a list as an argument, not the list itself represented as a pipe-delimited string. Since %push returns a new list, do you really have a variable named "test"|[whatever was already there] to pop the left item from? Does %push("test",test) make sense in the context of what you're doing?
-Tarn |
|
|
|
 |
Tech GURU

Joined: 18 Oct 2000 Posts: 2733 Location: Atlanta, USA
|
Posted: Sat Nov 22, 2008 4:01 pm |
You know what... it was a brain lapse on my part. I need to be more focused and review when I post this. I tried some other examples of function within functions and they worked just fine.
 |
|
_________________ Asati di tempari! |
|
|
 |
|
|
|