Divert target vars via more interp extension. Close #48
This commit is contained in:
41
examples/divert-vars/main.hank
Normal file
41
examples/divert-vars/main.hank
Normal file
@@ -0,0 +1,41 @@
|
||||
~ var target = ->knot1;
|
||||
-> start
|
||||
|
||||
== start
|
||||
|
||||
-> @target
|
||||
|
||||
= stitch1
|
||||
Text 3
|
||||
~ target = ->stitch2;
|
||||
-> start
|
||||
= stitch2
|
||||
Text 4
|
||||
~ target = ->gather1
|
||||
-> start
|
||||
- (gather1)
|
||||
Woooow!
|
||||
~target = ->finish.real_finish.real_tricky;
|
||||
->start
|
||||
|
||||
== knot1
|
||||
|
||||
Text 1
|
||||
~ target = ->knot2
|
||||
-> start
|
||||
|
||||
== knot2
|
||||
|
||||
Text 2
|
||||
~ target = ->finish;
|
||||
-> start
|
||||
|
||||
== finish
|
||||
|
||||
Seems to have worked! Time to get more complicated.
|
||||
~target = ->start.stitch1
|
||||
->start
|
||||
|
||||
= real_finish
|
||||
|
||||
- (real_tricky) That's incredible.
|
||||
7
examples/divert-vars/test1.hlog
Normal file
7
examples/divert-vars/test1.hlog
Normal file
@@ -0,0 +1,7 @@
|
||||
Text 1
|
||||
Text 2
|
||||
Seems to have worked! Time to get more complicated.
|
||||
Text 3
|
||||
Text 4
|
||||
Woooow!
|
||||
That's incredible.
|
||||
Reference in New Issue
Block a user