mirror of
https://github.com/flynx/pWiki.git
synced 2025-10-28 09:30:07 +00:00
figured out one issue, not sure how to resole it yet (see notes)
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
3e5a6e613e
commit
4bc3fc6022
@ -2198,8 +2198,7 @@ module.System = {
|
||||
<slot content>
|
||||
<h1><slot title>@source(./title/quote/!)</slot></h1>
|
||||
@include(.:$ARGS join="@source(file-separator)" recursive="")
|
||||
</slot>
|
||||
` },
|
||||
</slot>` },
|
||||
// XXX add join...
|
||||
_raw: {
|
||||
text: '@quote(.)' },
|
||||
|
||||
@ -450,6 +450,12 @@ module.BaseParser = {
|
||||
ast
|
||||
: ast.iter()
|
||||
|
||||
// XXX this must execute sequentially for things that depend on
|
||||
// lexical scope not to get lost in the mess...
|
||||
// ...or it's a question of if we can maintain "slices" of
|
||||
// state per macro call that is both containing all the state
|
||||
// from previous macros, and is not affected by the changes
|
||||
// done by next macros (unless needed)...
|
||||
return Promise.iter(ast,
|
||||
function(value){
|
||||
// text block...
|
||||
|
||||
20
pwiki2.js
20
pwiki2.js
@ -53,6 +53,26 @@
|
||||
* .resolve(..)
|
||||
* .parse(..)
|
||||
* - not handling the return value correctly in one or more macros
|
||||
* seems to be an issue with slots (content) not being filled...
|
||||
* could this be an issue with sequencing, i.e. trying to fill
|
||||
* the slot BEFORE it got a value???
|
||||
* ...but if this is the case, how could we have reached a point
|
||||
* where we reached a point where something is needed after it
|
||||
* is introduced but before it had a change to run???
|
||||
* (looks like the definition of what Promise.iter(..) is supposed
|
||||
* to do -> we need a way to carefully wait for all the prior
|
||||
* stuff to finish before filling slots)
|
||||
* XXX this is an interesting question, we need to maintain
|
||||
* the "illusion" lexical scope (i.e. code order) regardless
|
||||
* of actual order of execution...
|
||||
* ...this has to be done in both directions, i.e. we need to
|
||||
* wait for what came before and what comes after must
|
||||
* wait for us...
|
||||
* ...one simple way out of this is to do a less general
|
||||
* Promise.orderedIter(..) that will always execute in
|
||||
* order... (seems the simplest, we'll try this first)
|
||||
* ...this also feels a fundamental enough feature to
|
||||
* be implemented in ig-types
|
||||
* XXX ASAP need to add error handling to .awaitOrRun(..)
|
||||
* ...might be even better to make it support the same interface as Promise...
|
||||
* XXX BUG: for some reason editing the root page ('/') hangs /tree...
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user