Imperative Metaprogramming of a Declarative Program

A few people have been curious: Why am I modeling a multi stack environment in Awelon? Doesn’t this seem imperative? Isn’t the goal of relatively declarative models like reactive demand programming to get away from that?

Traditionally, a dataflow model might be programmed with boxes and wires.

The stacks in Awelon essentially model the imperative process of editing wires and boxes into an application. The stack carries wires and boxes – signals and blocks – as first-class elements. By modeling the editing process with code, it becomes possible to abstract it. Those abstractions are fine grained, higher order, ad hoc, adaptive, modeling reusable software components, smart wiring logic, deep wiring, complicated scatter/gather patterns, and repetition.

Imperative metaprogramming of a declarative program is perhaps the opposite of what most people expect. But it is very effective. The declarative target makes reasoning about the imperative code much simpler. In return, the imperative code allows precise, ad-hoc construction of complicated declarative models. Also, the imperative process performs predictably, which is important.

Awelon programmers will be capable of developing dataflow applications that are orders of magnitude larger and more complicated than boxes and wires languages, and thus able to address a wider variety of problem domains.

Advertisements
This entry was posted in Language Design, Reactive Demand Programming, UserInterface. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s