Stateful match specifications

Previous Topic Next Topic
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Stateful match specifications

Guilherme Andrade
Hi list,

I've recently wondered whether it would be useful (and feasible) to have support for 'stateful match specifications'; i.e., something along the lines of:

   ets:fun2ms(fun (Head, StateAcc) when Guards -> {Body, NewStateAcc} end, InitialState)

... as well as a corresponding extension to the raw match specifications format. These could then be optionally and transparently used in ets, tracing, etc.

What do you think? Perhaps the 'eeps' mailing list is a more appropriate place for making this proposal?


erlang-questions mailing list
[hidden email]