Next milestone - clean typesafe defintion with simple Implementation.
Next task - reenable "by" clause, using Macros
Merge remote-tracking branch 'origin/master'
Bucketing now works, though needs an ()=>Bucket generator.
Next step is to use macros to lift an expression to a generator function.
Ok, bucketing working with macros.
Loads of cargo-cult coding to unpick later.
Still got problems with mismatch of static return type for macro and actual macro return (I had to make macro statically return BucketBuilder[Any] rather than BucketBuilder[Term[Y]]
Working on getting chaining working and realised that my asInstanceOf coercion is very bad (and can't work).
Got a really simple compile fail example in MacroCompileError.scala to work on the typing
Ok, major reshuffle of project hierarchy after I discovered that a macro impl can return an instance of a thing with the macro def.
 I'd thought that the combination of "macros can't implement abstract methods" and "macro def has to be in a distinct compilation unit to usage" meant that I had to do evil workarounds to get chained macros like: Foo.doMacro().doMacro().doMacro()

 Turns out all I needed was the actual test program in a different unit. Anyway, I've got full Term bucketing / chaining now. Hurrah!
Added a 'join' and 'take' primitive for joining 2 streams into a stream of tuples. There's something a bit unsatisfying with this, as I can't express which element 'hasChanged'. Maybe I'd need my own tuple classes. Ugh.

got generalised 'reduce while true' stream working.
This allows us to emit a sequence of reductions, with each reduction emitting when a boolean stream transitions from true->false.
This is a building-block for being able to do time-segment reductions (e.g. accumulate accVol during market hours and then emit on the close).

Shame I couldn't simply use 'join' and 'filter' for this (due to being unable to tell which element in the tuple has fired). Ok, I could have constructed a tuple stream of fire states, but that is just getting really messy for unecessary purity.