stealth icon indicating copy to clipboard operation
stealth copied to clipboard

Add support for Array types in handle_message

Open mgomes opened this issue 5 years ago • 0 comments

Given this code:

handle_message(
  [:yes, :maybe] => proc { step_to state: :proceed }
  :no => proc { step_to state: :goodbye } 
)

Stealth could execute the first arm if either :yes or :maybe are specified. Both would still map to the alpha literal A though. But this way, a developer can specify multiple replies that map to a single proc making their handle_message more DRY.

mgomes avatar Sep 01 '20 21:09 mgomes