Re: Is there a good Windows or cross-platform Euphoria IDE?
- Posted by dcuny Oct 20, 2015
- 8787 views
ghaberek said...
I learned a while ago that when routine_id() is called as a part of a default parameter, it runs in the caller's scope, so that it returns the expected result at the point of the call.
You've got to be kidding me.
I just went round in circles with this. I wanted to write:
function create_callback(sequence routineName) integer routineId = routine_id(routineName) ... end function
But it scoped the visibility of the routines to where it was defined instead of where it was called. I ended up having to write:
function create_callback(integer routineId) ... end function
And got halfway through also writing a little rant about it before deciding not to press the post button...
Is this documented somewhere? I don't see it in the manual, and I just looked again.
- David