[erlang-questions] Intrusive function intercept

Richard A. O'Keefe <>
Sun Oct 13 23:56:45 CEST 2013


On 11/10/2013, at 10:19 PM, Tyron Zerafa wrote:

> First - I do not want to clutter my code with do_something(); I need this perform this call multiple times at different places.
> Second - do_something() performs some access control logic, test() is any other function accessing resources. Ideally, developers writing test() functions wouldn't have to worry about access control (this should be hidden).

This sounds like aspect-oriented programming,
and as such suffers from the rather severe problem of
aspect-oriented programming,
which is that what you see is not what runs.
How can you have any confidence in your code if it
might be taken over and do who knows what?

Sounds like a case for parse_transform, anyway.


More information about the erlang-questions mailing list