This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/app/debiki/Nashorn.scala b/app/debiki/Nashorn.scala | |
index 13f9f2eb4..bdc2604a7 100644 | |
--- a/app/debiki/Nashorn.scala | |
+++ b/app/debiki/Nashorn.scala | |
@@ -22,8 +22,7 @@ import java.io.{BufferedWriter, FileWriter} | |
import com.debiki.core._ | |
import com.debiki.core.Prelude._ | |
import java.{io => jio} | |
- | |
-import javax.{script => js} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- HUMAN RESOURCE MACHINE PROGRAM -- | |
COMMENT 4 | |
COPYFROM 24 | |
COPYTO 19 | |
BUMPUP 19 | |
BUMPUP 19 | |
COMMENT 3 | |
a: | |
COPYFROM 24 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- HUMAN RESOURCE MACHINE PROGRAM -- | |
COMMENT 0 | |
a: | |
COPYFROM 24 | |
COPYTO 20 | |
COPYFROM 24 | |
COPYTO 23 | |
b: | |
c: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- HUMAN RESOURCE MACHINE PROGRAM -- | |
COMMENT 4 | |
COPYFROM 24 | |
COPYTO 19 | |
BUMPUP 19 | |
BUMPUP 19 | |
COMMENT 3 | |
a: | |
COPYFROM 24 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Main where | |
import Prelude | |
import Data.DOM.Simple.Document | |
import Data.DOM.Simple.Element | |
import Data.DOM.Simple.Window | |
import qualified VirtualDOM as VD | |
import qualified VirtualDOM.VTree as VT | |
foreign import isoTS :: DOM.Node -> Data.DOM.Simple.Types.HTMLElement |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(def ^:dynamic *fix-tree-adjunctions*) | |
(defn record-adjunct | |
"Records an adjunction performed within fix-tree." | |
[phrase adjunct] | |
(if (thread-bound? #'*fix-tree-adjunctions*) | |
(set! *fix-tree-adjunctions* (conj *fix-tree-adjunctions* | |
{:phrase phrase | |
:adjunct adjunct})))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(def ^:dynamic *fix-tree-adjunctions*) | |
(def ^:dynamic *fix-tree-current-name*) | |
(defn record-adjunct | |
"Records an adjunction performed within fix-tree." | |
[phrase adjunct] | |
(if (thread-bound? #'*fix-tree-adjunctions*) | |
(let [record {:phrase phrase | |
:adjunct adjunct} | |
record (if (thread-bound? #'*fix-tree-current-name*) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(def ^:dynamic *current-tree-name*) | |
(defn record-adjunct | |
"Records an adjunction performed by our rules." | |
[phrase adjunct] | |
(swap! adjunctions conj {:name *current-tree-name* | |
:phrase phrase | |
:adjunct adjunct})) | |
(def fixed-trees |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defn record-adjunct | |
"Records an adjunction performed by our rules." | |
[phrase adjunct] | |
(swap! adjunctions conj {:name name | |
:phrase phrase | |
:adjunct adjunct})) | |
(def fixed-trees | |
"A map from tree filenames to their fixed versions." | |
(into {} (for [[name tree] trees] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defmacro transformo | |
"Is satisfied when out-tree is a normalized version of the in-tree | |
node. Tries to use any goal annotated with ::rule." | |
[in-tree out-tree] | |
`(conde ~@(for [[sym var] (ns-interns *ns*) | |
:when (::rule (meta var))] | |
[(list sym in-tree out-tree)]))) |
NewerOlder