Re: routine_id() - Suggestion

new topic     » topic index » view thread      » older message » newer message

Short and to the point (I'm sure I've mentioned this before):

Wouldn't it be possible to make function names, without their parameters,
usable as variables, with the integer value that would be their
routine_id()?

Then we can do things like [this particularly bad example blink]:

function foobar(integer foo, atom bar)
    return foo + foo * (bar - floor(bar))
end function

-- Other functions

ids = {foobar, other, something, square_it}
number = call_func(ids[rand(length(ids))], {5, 5.6})

Carl

--
.sig-gone it.

new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu