diff --git a/Graph-notes-copy2.vue b/Graph-notes-copy2.vue index fc34995..bf02533 100644 --- a/Graph-notes-copy2.vue +++ b/Graph-notes-copy2.vue @@ -1,14 +1,14 @@ <!-- Tufts VUE 3.3.0 concept-map (Graph-notes-copy2.vue) 2017-01-16 --> <!-- Tufts VUE: http://vue.tufts.edu/ --> <!-- Do Not Remove: VUE mapping @version(1.1) jar:file:/nix/store/z92y35qgs6g3cvvh0i4f14mg5n47zvvi-vue-3.3.0/share/vue/vue.jar!/tufts/vue/resources/lw_mapping_1_1.xml --> -<!-- Do Not Remove: Saved date Mon Jan 16 01:54:56 CET 2017 by georges on platform Linux 4.4.38 in JVM 1.8.0_122-04 --> +<!-- Do Not Remove: Saved date Mon Jan 16 09:59:19 CET 2017 by georges on platform Linux 4.4.38 in JVM 1.8.0_122-04 --> <!-- Do Not Remove: Saving version @(#)VUE: built October 8 2015 at 1724 by tomadm on Linux 2.6.32-504.23.4.el6.x86_64 i386 JVM 1.7.0_21-b11(bits=32) --> <?xml version="1.0" encoding="US-ASCII"?> <LW-MAP xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="none" ID="0" label="Graph-notes-copy2.vue" created="1479309847604" x="0.0" y="0.0" width="1.4E-45" height="1.4E-45" strokeWidth="0.0" autoSized="false"> - <resource referenceCreated="1484528096110" size="208901" + <resource referenceCreated="1484557159072" size="211457" spec="/home/georges/phc/racket-packages/phc-graph/Graph-notes-copy2.vue" type="1" xsi:type="URLResource"> <title>Graph-notes-copy2.vue</title> @@ -3778,12 +3778,59 @@ <ID1 xsi:type="node">540</ID1> <ID2 xsi:type="node">542</ID2> </child> + <child ID="544" label="Check addition of new fields to the input" + layerID="1" created="1484557019620" x="2235.3042" y="324.74472" + width="274.0" height="23.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> + <fillColor>#F2AE45</fillColor> + <strokeColor>#776D6D</strokeColor> + <textColor>#000000</textColor> + <font>SansSerif-plain-12</font> + <URIString>http://vue.tufts.edu/rdf/resource/a68081d4c0a801286ae39894efbfa682</URIString> + <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> + </child> + <child ID="545" layerID="1" created="1484557019630" x="1975.7919" + y="347.24472" width="335.61157" height="63.670532" + strokeWidth="1.0" autoSized="false" controlCount="0" + arrowState="2" xsi:type="link"> + <strokeColor>#404040</strokeColor> + <textColor>#404040</textColor> + <font>SansSerif-plain-11</font> + <URIString>http://vue.tufts.edu/rdf/resource/a68081d5c0a801286ae398949e441433</URIString> + <point1 x="1976.2917" y="410.41525"/> + <point2 x="2310.9033" y="347.74472"/> + <ID1 xsi:type="node">357</ID1> + <ID2 xsi:type="node">544</ID2> + </child> + <child ID="546" + label="By versionning the lists of fields,
and indicating the last-good version number
in the graph creation code — new versions have to be
approved by bumping the number." + layerID="1" created="1484557036779" x="2181.971" y="222.0781" + width="368.0" height="68.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> + <fillColor>#F2AE45</fillColor> + <strokeColor>#776D6D</strokeColor> + <textColor>#000000</textColor> + <font>SansSerif-plain-12</font> + <URIString>http://vue.tufts.edu/rdf/resource/a68081d5c0a801286ae398942effba1f</URIString> + <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> + </child> + <child ID="547" layerID="1" created="1484557036786" x="2368.157" + y="289.57812" width="3.7387695" height="35.66797" + strokeWidth="1.0" autoSized="false" controlCount="0" + arrowState="2" xsi:type="link"> + <strokeColor>#404040</strokeColor> + <textColor>#404040</textColor> + <font>SansSerif-plain-11</font> + <URIString>http://vue.tufts.edu/rdf/resource/a68081d6c0a801286ae398944c00f8fa</URIString> + <point1 x="2371.3958" y="324.7461"/> + <point2 x="2368.657" y="290.07812"/> + <ID1 xsi:type="node">544</ID1> + <ID2 xsi:type="node">546</ID2> + </child> <layer ID="1" label="Layer 1" created="1479309847607" x="0.0" y="0.0" width="1.4E-45" height="1.4E-45" strokeWidth="0.0" autoSized="false"> <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b15c0a80026548592b8d2f3fee2</URIString> </layer> - <userZoom>1.0</userZoom> - <userOrigin x="-1656.3625" y="-636.75525"/> + <userZoom>0.75</userZoom> + <userOrigin x="-1182.522" y="-189.81644"/> <presentationBackground>#FFFFFF</presentationBackground> <PathwayList currentPathway="0" revealerIndex="-1"> <pathway ID="0" label="Chemin sans nom" created="1479309847603" diff --git a/Graph-notes.mm b/Graph-notes.mm deleted file mode 100644 index 7451ae9..0000000 --- a/Graph-notes.mm +++ /dev/null @@ -1,50 +0,0 @@ -<map version="1.0.1"> -<!-- To view this file, download free mind mapping software FreeMind from http://freemind.sourceforge.net --> -<node CREATED="1479307928543" ID="ID_115580742" MODIFIED="1479308216259" TEXT="Graph"> -<font NAME="SansSerif" SIZE="16"/> -<node CREATED="1479307978656" ID="ID_1467790846" MODIFIED="1479308216235" POSITION="right" TEXT=""> -<font NAME="SansSerif" SIZE="16"/> -</node> -<node CREATED="1479308005979" ID="ID_1461725970" MODIFIED="1479308216211" POSITION="left" TEXT="invariants"> -<font NAME="SansSerif" SIZE="16"/> -<node CREATED="1479308061764" ID="ID_378722052" MODIFIED="1479308216188" TEXT="scope"> -<font NAME="SansSerif" SIZE="16"/> -<node CREATED="1479308065663" ID="ID_939090742" MODIFIED="1479308216164" TEXT="Input"> -<font NAME="SansSerif" SIZE="16"/> -</node> -<node CREATED="1479308091707" ID="ID_1563514202" MODIFIED="1479308216094" TEXT="Output"> -<font NAME="SansSerif" SIZE="16"/> -</node> -<node CREATED="1479308095316" ID="ID_1340973971" MODIFIED="1479308233811" TEXT="Transformation"> -<font NAME="SansSerif" SIZE="16"/> -<node CREATED="1479308237795" ID="ID_1309060989" MODIFIED="1479308254807" TEXT="like ->i"> -<font NAME="DejaVu Sans Mono" SIZE="12"/> -</node> -</node> -</node> -<node CREATED="1479308274575" ID="ID_1586701005" MODIFIED="1479308282949" TEXT="Verification time"> -<node CREATED="1479308293860" ID="ID_46833274" MODIFIED="1479308297548" TEXT="Run-time"/> -<node CREATED="1479308298132" ID="ID_170224426" MODIFIED="1479308304972" TEXT="Compile-time"> -<node CREATED="1479308308988" ID="ID_1071628135" MODIFIED="1479308321217" TEXT="Field types"/> -<node CREATED="1479308325655" ID="ID_1497263973" MODIFIED="1479308474005" TEXT="Type policy"> -<node CREATED="1479308366808" ID="ID_1203881216" MODIFIED="1479308368145" TEXT="e.g. no cycles within the types"/> -</node> -<node CREATED="1479308372692" ID="ID_1614080405" MODIFIED="1479308442436" TEXT="Macro policy"> -<node CREATED="1479308444994" ID="ID_1687400809" MODIFIED="1479308450313" TEXT="i.e. correct by construction"/> -<node CREATED="1479308486419" FOLDED="true" ID="ID_1005390685" MODIFIED="1479308873487" TEXT="May interfere with each other"> -<icon BUILTIN="messagebox_warning"/> -<node CREATED="1479308564613" ID="ID_246345249" MODIFIED="1479308870465" STYLE="bubble" TEXT="e.g. a "no cycles starting from this node" constraint
would not work as expected if a "backwards link" is
filled in afterwards.
We probably need to hardcode a basic set of
constraints which know about each other and
about the potential interactions."/> -</node> -<node CREATED="1479308516231" FOLDED="true" ID="ID_521874707" MODIFIED="1479309080946" TEXT="May alter a mapping's inputs"> -<node CREATED="1479308984967" ID="ID_666428602" MODIFIED="1479309027685" TEXT="Conserve well-scopedness within a transition:
pass in nodes flagged with a ∀ type, and
check that the output contains that flag.
Potentially out-of-scope fields in the input do
not have the flag."/> -</node> -<node CREATED="1479308767829" ID="ID_1128145279" MODIFIED="1479308903893" TEXT="May wrapp a mapping's outputs"> -<node CREATED="1479308905956" ID="ID_1856836622" MODIFIED="1479308919205" TEXT="e.g. wrap with (ann)"/> -</node> -</node> -</node> -</node> -<node CREATED="1479308289261" ID="ID_1896946451" MODIFIED="1479308292028" TEXT="Specification"/> -</node> -</node> -</map> diff --git a/Graph-notes.vue b/Graph-notes.vue deleted file mode 100644 index 5ea38dd..0000000 --- a/Graph-notes.vue +++ /dev/null @@ -1,1064 +0,0 @@ -<!-- Tufts VUE 3.3.0 concept-map (Graph-notes.vue) 2016-11-16 --> -<!-- Tufts VUE: http://vue.tufts.edu/ --> -<!-- Do Not Remove: VUE mapping @version(1.1) jar:file:/nix/store/miyaz9by4k195j53sbl6mgyky60xqjf1-vue-3.3.0/share/vue/vue.jar!/tufts/vue/resources/lw_mapping_1_1.xml --> -<!-- Do Not Remove: Saved date Wed Nov 16 16:56:32 CET 2016 by georges on platform Linux 4.4.26 in JVM 1.8.0_76-00 --> -<!-- Do Not Remove: Saving version @(#)VUE: built October 8 2015 at 1724 by tomadm on Linux 2.6.32-504.23.4.el6.x86_64 i386 JVM 1.7.0_21-b11(bits=32) --> -<?xml version="1.0" encoding="US-ASCII"?> -<LW-MAP xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:noNamespaceSchemaLocation="none" ID="0" label="Graph-notes.vue" - created="1479309847604" x="0.0" y="0.0" width="1.4E-45" - height="1.4E-45" strokeWidth="0.0" autoSized="false"> - <resource referenceCreated="1479311792842" size="54675" - spec="/home/georges/phc/racket-packages/phc-graph/Graph-notes.vue" - type="1" xsi:type="URLResource"> - <title>Graph-notes.vue</title> - <property key="File" value="/home/georges/phc/racket-packages/phc-graph/Graph-notes.vue"/> - </resource> - <fillColor>#FFFFFF</fillColor> - <strokeColor>#404040</strokeColor> - <textColor>#000000</textColor> - <font>SansSerif-plain-14</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6af7c0a80026548592b8dffca40a</URIString> - <child ID="6" label="Graph" layerID="1" created="1479309863303" - x="1356.0449" y="544.30304" width="45.0" height="22.0" - strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6afcc0a80026548592b833e3a781</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="7" label="Auto-generation of mappings" layerID="1" - created="1479309887096" x="1428.5449" y="544.30304" - width="170.0" height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#8AEE95</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6afec0a80026548592b88abb8384</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="8" layerID="1" created="1479309887097" x="1400.5449" - y="554.80304" width="28.5" height="1.0" strokeWidth="1.0" - autoSized="false" controlCount="0" arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6affc0a80026548592b80b4ee7cc</URIString> - <point1 x="1401.0449" y="555.30304"/> - <point2 x="1428.5449" y="555.30304"/> - <ID1 xsi:type="node">6</ID1> - <ID2 xsi:type="node">7</ID2> - </child> - <child ID="9" label="As a wrapper?" layerID="1" - created="1479309895903" x="1653.57" y="546.05414" width="90.0" - height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b00c0a80026548592b8a0766ac6</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="10" layerID="1" created="1479309895904" x="1598.0449" - y="555.60754" width="56.025024" height="1.520752" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b01c0a80026548592b8a5bb4d0a</URIString> - <point1 x="1598.5449" y="556.10754"/> - <point2 x="1653.57" y="556.6283"/> - <ID1 xsi:type="node">7</ID1> - <ID2 xsi:type="node">9</ID2> - </child> - <child ID="11" label="Structural equality" layerID="1" - created="1479309904736" x="1324.5449" y="679.30304" - width="108.0" height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#8AEE95</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b03c0a80026548592b81914701e</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="12" layerID="1" created="1479309904738" x="1378.0449" - y="565.80304" width="1.0" height="114.0" strokeWidth="1.0" - autoSized="false" controlCount="0" arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b04c0a80026548592b8c27d0837</URIString> - <point1 x="1378.5449" y="566.30304"/> - <point2 x="1378.5449" y="679.30304"/> - <ID1 xsi:type="node">6</ID1> - <ID2 xsi:type="node">11</ID2> - </child> - <child ID="13" label="Invariants" layerID="1" - created="1479309905789" x="1195.0447" y="544.30304" width="64.0" - height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#8AEE95</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b05c0a80026548592b80343782b</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="14" layerID="1" created="1479309905791" x="1258.5447" - y="554.80304" width="98.000244" height="1.0" strokeWidth="1.0" - autoSized="false" controlCount="0" arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b06c0a80026548592b870fb7c6a</URIString> - <point1 x="1356.0449" y="555.30304"/> - <point2 x="1259.0447" y="555.30304"/> - <ID1 xsi:type="node">6</ID1> - <ID2 xsi:type="node">13</ID2> - </child> - <child ID="15" label="Other" layerID="1" created="1479309906604" - x="1358.0449" y="409.30307" width="41.0" height="22.0" - strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b07c0a80026548592b8f5e19e10</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="16" layerID="1" created="1479309906606" x="1378.0449" - y="430.80304" width="1.0" height="113.99997" strokeWidth="1.0" - autoSized="false" controlCount="0" arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b08c0a80026548592b840ee8fa0</URIString> - <point1 x="1378.5449" y="544.30304"/> - <point2 x="1378.5449" y="431.30307"/> - <ID1 xsi:type="node">6</ID1> - <ID2 xsi:type="node">15</ID2> - </child> - <child ID="17" label="Scope" layerID="1" created="1479309922342" - x="1074.125" y="412.36423" width="46.0" height="22.0" - strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b09c0a80026548592b8217a1807</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="18" layerID="1" created="1479309922344" x="1107.4567" - y="433.8642" width="109.25635" height="110.93884" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b09c0a80026548592b8dfab693e</URIString> - <point1 x="1216.213" y="544.30304"/> - <point2 x="1107.9567" y="434.3642"/> - <ID1 xsi:type="node">13</ID1> - <ID2 xsi:type="node">17</ID2> - </child> - <child ID="19" label="Verification time" layerID="1" - created="1479309923132" x="1048.125" y="547.8052" width="98.0" - height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b0ac0a80026548592b87ee8d14b</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="20" layerID="1" created="1479309923134" x="1145.5608" - y="555.66565" width="49.98401" height="2.3204346" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b11c0a80026548592b89f9e9272</URIString> - <point1 x="1195.0447" y="556.16565"/> - <point2 x="1146.0607" y="557.4861"/> - <ID1 xsi:type="node">13</ID1> - <ID2 xsi:type="node">19</ID2> - </child> - <child ID="21" label="Specification" layerID="1" - created="1479309923917" x="1056.625" y="692.8775" width="81.0" - height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b12c0a80026548592b83be06baa</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="22" layerID="1" created="1479309923919" x="1106.2439" - y="565.803" width="111.681885" height="127.57446" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b13c0a80026548592b8f03d2a45</URIString> - <point1 x="1217.4258" y="566.303"/> - <point2 x="1106.7439" y="692.87744"/> - <ID1 xsi:type="node">13</ID1> - <ID2 xsi:type="node">21</ID2> - </child> - <child ID="23" label="Coloring" layerID="1" created="1479309940842" - x="1349.5449" y="327.30307" width="58.0" height="22.0" - strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#8AEE95</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b14c0a80026548592b8bc35fbb9</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="24" layerID="1" created="1479309940844" x="1378.0449" - y="348.80307" width="1.0" height="61.0" strokeWidth="1.0" - autoSized="false" controlCount="0" arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b14c0a80026548592b87410806e</URIString> - <point1 x="1378.5449" y="409.30307"/> - <point2 x="1378.5449" y="349.30307"/> - <ID1 xsi:type="node">15</ID1> - <ID2 xsi:type="node">23</ID2> - </child> - <child ID="25" label="Coalesce nodes which are equal?" layerID="1" - created="1479310031080" x="1279.0449" y="895.30304" - width="199.0" height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dc1a307c0a80026548592b8c2af76c4</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="26" layerID="1" created="1479310031081" x="1378.0449" - y="700.80304" width="1.0" height="195.0" strokeWidth="1.0" - autoSized="false" controlCount="0" arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dc1a307c0a80026548592b8a04c0bf0</URIString> - <point1 x="1378.5449" y="701.30304"/> - <point2 x="1378.5449" y="895.30304"/> - <ID1 xsi:type="node">11</ID1> - <ID2 xsi:type="node">25</ID2> - </child> - <child ID="27" label="Hash consing" layerID="1" - created="1479310041195" x="1133.1572" y="1014.7637" width="88.0" - height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dc1a308c0a80026548592b8ff6b1596</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="28" layerID="1" created="1479310041197" x="1195.201" - y="916.80304" width="165.30005" height="98.46069" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dc1a308c0a80026548592b8be3bbbf2</URIString> - <point1 x="1360.0011" y="917.30304"/> - <point2 x="1195.701" y="1014.76373"/> - <ID1 xsi:type="node">25</ID1> - <ID2 xsi:type="node">27</ID2> - </child> - <child ID="29" - label="= deterministic finite automaton minimization
(when there are no unordered sets)" - layerID="1" created="1479310064475" x="1084.6282" y="1141.0577" - width="256.0" height="36.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dc1a309c0a80026548592b84e893214</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="33" label="=" layerID="1" created="1479310109124" - x="1297.7559" y="1027.0216" width="18.0" height="22.0" - strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dc1a30ac0a80026548592b8ea42a1af</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="34" layerID="1" created="1479310109126" x="1311.2246" - y="916.803" width="61.825073" height="112.60205" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dc1a30ac0a80026548592b87117f4c4</URIString> - <point1 x="1372.5497" y="917.303"/> - <point2 x="1311.7246" y="1028.905"/> - <ID1 xsi:type="node">25</ID1> - <ID2 xsi:type="node">33</ID2> - </child> - <child ID="35" layerID="1" created="1479310112683" x="1226.1265" - y="1045.6342" width="74.820435" height="95.923584" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dc1a30bc0a80026548592b83098fe4a</URIString> - <point1 x="1300.4469" y="1046.1342"/> - <point2 x="1226.6265" y="1141.0577"/> - <ID1 xsi:type="node">33</ID1> - <ID2 xsi:type="node">29</ID2> - </child> - <child ID="36" - label="= deterministic finite automaton minimization
(when there are unordered sets)" - layerID="1" created="1479310130202" x="1346.1924" y="1143.4769" - width="256.0" height="36.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dc1a30bc0a80026548592b8e12add9f</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="37" layerID="1" created="1479310130203" x="1314.0364" - y="1043.2584" width="136.24341" height="100.718506" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dc1a30cc0a80026548592b879e5ac96</URIString> - <point1 x="1314.5364" y="1043.7584"/> - <point2 x="1449.7798" y="1143.4769"/> - <ID1 xsi:type="node">33</ID1> - <ID2 xsi:type="node">36</ID2> - </child> - <child ID="42" - label="Cache all calls to equal? while grouping nodes" - layerID="1" created="1479310644302" x="1362.7698" y="1029.8263" - width="268.0" height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dc99799c0a80026548592b87d2d4299</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="43" layerID="1" created="1479310644303" x="1387.7122" - y="916.803" width="99.89038" height="113.52338" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dc99799c0a80026548592b80979537c</URIString> - <point1 x="1388.2122" y="917.30304"/> - <point2 x="1487.1025" y="1029.8264"/> - <ID1 xsi:type="node">25</ID1> - <ID2 xsi:type="node">42</ID2> - </child> - <child ID="44" - label="Allows fast comparison of nodes within the same graph" - layerID="1" created="1479310691911" x="1539.634" y="991.3014" - width="315.0" height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dcae10dc0a80026548592b847b6398e</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="45" layerID="1" created="1479310691912" x="1414.5505" - y="916.8031" width="246.57788" height="74.99835" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dcae10dc0a80026548592b8f409d90b</URIString> - <point1 x="1415.0505" y="917.30304"/> - <point2 x="1660.6284" y="991.3014"/> - <ID1 xsi:type="node">25</ID1> - <ID2 xsi:type="node">44</ID2> - </child> - <child ID="46" label="Input" layerID="1" created="1479310829020" - x="752.50134" y="296.97845" width="38.0" height="22.0" - strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dcc34bcc0a80026548592b8808f2759</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="47" layerID="1" created="1479310829021" x="788.3656" - y="313.63153" width="288.6665" height="102.93555" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dcc34bcc0a80026548592b8748a3e11</URIString> - <point1 x="1076.5321" y="416.06708"/> - <point2 x="788.8656" y="314.13153"/> - <ID1 xsi:type="node">17</ID1> - <ID2 xsi:type="node">46</ID2> - </child> - <child ID="48" label="Output" layerID="1" created="1479310833975" - x="752.50134" y="360.89468" width="47.0" height="22.0" - strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dcc34bcc0a80026548592b879d2f6dd</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="49" layerID="1" created="1479310833976" x="798.4603" - y="375.07452" width="276.68994" height="45.18744" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dcc34bcc0a80026548592b88a1654a6</URIString> - <point1 x="1074.6503" y="419.76196"/> - <point2 x="798.9603" y="375.57452"/> - <ID1 xsi:type="node">17</ID1> - <ID2 xsi:type="node">48</ID2> - </child> - <child ID="50" label="Transformation" layerID="1" - created="1479310838279" x="752.50134" y="408.17514" width="95.0" - height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dcc34bcc0a80026548592b822f951f1</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="51" layerID="1" created="1479310838280" x="847.00134" - y="419.34485" width="227.62366" height="4.195099" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dcc34bcc0a80026548592b83b7795c3</URIString> - <point1 x="1074.125" y="423.03995"/> - <point2 x="847.50134" y="419.84485"/> - <ID1 xsi:type="node">17</ID1> - <ID2 xsi:type="node">50</ID2> - </child> - <child ID="52" label="Like ->i" layerID="1" created="1479310857171" - x="752.50134" y="439.6955" width="59.399998" height="25.399998" - strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#BDE5F2</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dcc935cc0a80026548592b89128dae1</URIString> - <shape xsi:type="ellipse"/> - </child> - <child ID="53" layerID="1" created="1479310857172" x="788.2053" - y="429.67517" width="6.4020386" height="11.081787" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dcc935cc0a80026548592b8c6445100</URIString> - <point1 x="794.10736" y="430.17517"/> - <point2 x="788.7053" y="440.25696"/> - <ID1 xsi:type="node">50</ID1> - <ID2 xsi:type="node">52</ID2> - </child> - <child ID="54" label="Run-time" layerID="1" created="1479311002504" - x="752.50134" y="508.8651" width="62.0" height="22.0" - strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dcfe7a9c0a80026548592b81207b1b5</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="55" layerID="1" created="1479311002504" x="813.4403" - y="523.14453" width="236.65112" height="30.25885" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dcfe7a9c0a80026548592b8e2e22006</URIString> - <point1 x="1049.5914" y="552.9033"/> - <point2 x="813.9403" y="523.6445"/> - <ID1 xsi:type="node">19</ID1> - <ID2 xsi:type="node">54</ID2> - </child> - <child ID="56" label="Compile-time" layerID="1" - created="1479311005524" x="752.50134" y="564.90125" width="86.0" - height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dcfe7a9c0a80026548592b89d70c39f</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="57" layerID="1" created="1479311005525" x="837.71436" - y="561.0624" width="211.26538" height="12.917847" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dcfe7aac0a80026548592b8bb000cae</URIString> - <point1 x="1048.4797" y="561.5624"/> - <point2 x="838.21436" y="573.4802"/> - <ID1 xsi:type="node">19</ID1> - <ID2 xsi:type="node">56</ID2> - </child> - <child ID="58" label="Invariants on the graph/node type" layerID="1" - created="1479311020061" x="772.63934" y="671.72015" - width="192.0" height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dcfe7aac0a80026548592b8b15cb8ab</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="59" layerID="1" created="1479311020062" x="960.49695" - y="690.7722" width="97.17316" height="9.905457" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dcfe7aac0a80026548592b8be3b9e4e</URIString> - <point1 x="1057.17" y="700.17773"/> - <point2 x="960.9969" y="691.2723"/> - <ID1 xsi:type="node">21</ID1> - <ID2 xsi:type="node">58</ID2> - </child> - <child ID="60" label="Enforcement on the transform or creation" - layerID="1" created="1479311044058" x="772.63934" y="747.01874" - width="235.0" height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dcfe7aac0a80026548592b87a0fd91a</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="61" layerID="1" created="1479311044059" x="931.6931" - y="712.714" width="130.23785" height="34.80475" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dcfe7aac0a80026548592b8c1f4be82</URIString> - <point1 x="1061.4309" y="713.214"/> - <point2 x="932.19305" y="747.01874"/> - <ID1 xsi:type="node">21</ID1> - <ID2 xsi:type="node">60</ID2> - </child> - <child ID="65" label="Field types" layerID="1" - created="1479311202294" x="394.1343" y="374.1304" width="70.0" - height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd2c0a80026548592b8b52eab6a</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="68" label="Type policy" layerID="1" - created="1479311229819" x="387.50537" y="527.25195" width="71.0" - height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd2c0a80026548592b8d3f60760</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="71" layerID="1" created="1479311237412" x="452.83752" - y="429.67517" width="312.83786" height="99.49625" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd2c0a80026548592b834c49dca</URIString> - <point1 x="765.1754" y="430.17514"/> - <point2 x="453.33755" y="528.6714"/> - <ID1 xsi:type="node">50</ID1> - <ID2 xsi:type="node">68</ID2> - </child> - <child ID="72" label="I/O" layerID="1" created="1479311259082" - x="752.50134" y="330.2499" width="26.0" height="22.0" - strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd2c0a80026548592b860a16421</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="73" layerID="1" created="1479311259083" x="766.985" - y="318.47852" width="3.0326538" height="12.271484" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd3c0a80026548592b87d773be5</URIString> - <point1 x="769.5177" y="318.97852"/> - <point2 x="767.48505" y="330.25"/> - <ID1 xsi:type="node">46</ID1> - <ID2 xsi:type="node">72</ID2> - </child> - <child ID="74" layerID="1" created="1479311273455" x="768.7206" - y="351.6046" width="4.01178" height="9.790039" strokeWidth="1.0" - autoSized="false" controlCount="0" arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd3c0a80026548592b8fba10e52</URIString> - <point1 x="772.23236" y="360.89465"/> - <point2 x="769.2206" y="352.1046"/> - <ID1 xsi:type="node">48</ID1> - <ID2 xsi:type="node">72</ID2> - </child> - <child ID="77" layerID="1" created="1479311290760" x="462.93283" - y="342.42795" width="290.20538" height="38.72809" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd3c0a80026548592b8c655a6f4</URIString> - <point1 x="752.63824" y="342.92795"/> - <point2 x="463.43286" y="380.65604"/> - <ID1 xsi:type="node">72</ID1> - <ID2 xsi:type="node">65</ID2> - </child> - <child ID="78" layerID="1" created="1479311293955" x="441.62943" - y="347.17944" width="313.19403" height="180.57254" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd3c0a80026548592b8aea1a2b1</URIString> - <point1 x="754.3234" y="347.6794"/> - <point2 x="442.1294" y="527.25195"/> - <ID1 xsi:type="node">72</ID1> - <ID2 xsi:type="node">68</ID2> - </child> - <child ID="79" layerID="1" created="1479311329601" x="449.75937" - y="395.63037" width="325.117" height="169.77084" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd3c0a80026548592b8f8515bcf</URIString> - <point1 x="774.37634" y="564.90125"/> - <point2 x="450.25934" y="396.1304"/> - <ID1 xsi:type="node">56</ID1> - <ID2 xsi:type="node">65</ID2> - </child> - <child ID="80" layerID="1" created="1479311331463" x="457.4933" - y="541.28827" width="296.17004" height="30.83374" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd3c0a80026548592b8b0891c54</URIString> - <point1 x="753.1633" y="571.622"/> - <point2 x="457.9933" y="541.78827"/> - <ID1 xsi:type="node">56</ID1> - <ID2 xsi:type="node">68</ID2> - </child> - <child ID="85" label="Both" layerID="1" created="1479311384944" - x="752.50134" y="706.74274" width="36.0" height="22.0" - strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd4c0a80026548592b8c0ff55ee</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="86" layerID="1" created="1479311384945" x="786.53564" - y="693.2201" width="51.780212" height="19.12201" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd4c0a80026548592b83f26b2af</URIString> - <point1 x="837.8159" y="693.72015"/> - <point2 x="787.0357" y="711.84216"/> - <ID1 xsi:type="node">58</ID1> - <ID2 xsi:type="node">85</ID2> - </child> - <child ID="87" layerID="1" created="1479311387913" x="786.71954" - y="722.87085" width="71.24475" height="24.647888" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd4c0a80026548592b8b1599cbd</URIString> - <point1 x="857.4643" y="747.01874"/> - <point2 x="787.21954" y="723.37085"/> - <ID1 xsi:type="node">60</ID1> - <ID2 xsi:type="node">85</ID2> - </child> - <child ID="88" layerID="1" created="1479311407577" x="439.9238" - y="395.63043" width="320.3526" height="312.1625" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd4c0a80026548592b8dae1d183</URIString> - <point1 x="759.7764" y="707.2929"/> - <point2 x="440.42383" y="396.1304"/> - <ID1 xsi:type="node">85</ID1> - <ID2 xsi:type="node">65</ID2> - </child> - <child ID="89" layerID="1" created="1479311409907" x="443.8015" - y="548.75195" width="311.98563" height="161.6322" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd4c0a80026548592b8d155bae3</URIString> - <point1 x="755.2871" y="709.88416"/> - <point2 x="444.30148" y="549.25195"/> - <ID1 xsi:type="node">85</ID1> - <ID2 xsi:type="node">68</ID2> - </child> - <child ID="90" label="Macro policy" layerID="1" - created="1479311433081" x="-25.623238" y="756.6499" width="78.0" - height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd4c0a80026548592b8697d13c4</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="92" layerID="1" created="1479311450475" x="752.50134" - y="746.1432" width="11.0" height="22.0" strokeWidth="1.0" - autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd4c0a80026548592b8efc854fb</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="93" layerID="1" created="1479311450476" x="763.00134" - y="756.6796" width="10.1380005" height="1.0605469" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd5c0a80026548592b80278dac6</URIString> - <point1 x="772.63934" y="757.2402"/> - <point2 x="763.50134" y="757.1796"/> - <ID1 xsi:type="node">60</ID1> - <ID2 xsi:type="node">92</ID2> - </child> - <child ID="94" layerID="1" created="1479311456599" x="752.50134" - y="669.09344" width="11.0" height="22.0" strokeWidth="1.0" - autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd5c0a80026548592b8d0bf4afd</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="95" layerID="1" created="1479311456600" x="763.00134" - y="679.724" width="10.395081" height="1.2230225" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd5c0a80026548592b8f824e3b9</URIString> - <point1 x="772.8964" y="680.447"/> - <point2 x="763.50134" y="680.224"/> - <ID1 xsi:type="node">58</ID1> - <ID2 xsi:type="node">94</ID2> - </child> - <child ID="101" label="No cycles within the types" layerID="1" - created="1479311579531" x="162.62317" y="524.62524" - width="151.0" height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd5c0a80026548592b8dfa424c8</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="102" layerID="1" created="1479311579532" x="313.10852" - y="536.1977" width="74.89682" height="2.0499268" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd5c0a80026548592b8d9e35c75</URIString> - <point1 x="387.50537" y="537.7476"/> - <point2 x="313.60855" y="536.6977"/> - <ID1 xsi:type="node">68</ID1> - <ID2 xsi:type="node">101</ID2> - </child> - <child ID="103" label="/!\ May interfere with each other" - layerID="1" created="1479311599825" x="-266.4179" y="708.4939" - width="178.0" height="22.0" strokeWidth="3.0" autoSized="true" xsi:type="node"> - <fillColor>#FEFEC9</fillColor> - <strokeColor>#EA2218</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd5c0a80026548592b8ddb5b6c7</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="104" layerID="1" created="1479311599826" x="-134.3357" - y="729.9939" width="113.256386" height="29.33319" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd5c0a80026548592b81da96232</URIString> - <point1 x="-21.579308" y="758.8271"/> - <point2 x="-133.8357" y="730.4939"/> - <ID1 xsi:type="node">90</ID1> - <ID2 xsi:type="node">103</ID2> - </child> - <child ID="105" label="May alter a mapping's inputs" layerID="1" - created="1479311627089" x="-255.41791" y="752.2721" - width="167.0" height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd6c0a80026548592b853276e56</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="106" layerID="1" created="1479311627089" x="-89.113365" - y="764.74023" width="63.990128" height="2.4882202" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd6c0a80026548592b89262c338</URIString> - <point1 x="-25.623238" y="766.72845"/> - <point2 x="-88.613365" y="765.24023"/> - <ID1 xsi:type="node">90</ID1> - <ID2 xsi:type="node">105</ID2> - </child> - <child ID="107" - label="May wrap or check or alter a mapping's outputs" - layerID="1" created="1479311633861" x="-342.96988" y="804.80597" - width="267.0" height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd6c0a80026548592b8c817c8d9</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="108" layerID="1" created="1479311633863" x="-159.0664" - y="774.9798" width="136.7095" height="30.326172" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#404040</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dd89bd6c0a80026548592b88ac312bd</URIString> - <point1 x="-22.856901" y="775.4798"/> - <point2 x="-158.5664" y="804.80597"/> - <ID1 xsi:type="node">90</ID1> - <ID2 xsi:type="node">107</ID2> - </child> - <child ID="109" label="Wrap with ann" layerID="1" - created="1479311725257" x="-330.71646" y="867.8466" width="89.0" - height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dda878ec0a80026548592b8416c8f4f</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="110" layerID="1" created="1479311725259" x="-273.3249" - y="826.30597" width="50.96341" height="42.04065" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#000000</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dda878ec0a80026548592b8d9e1112c</URIString> - <point1 x="-222.86148" y="826.80597"/> - <point2 x="-272.8249" y="867.8466"/> - <ID1 xsi:type="node">107</ID1> - <ID2 xsi:type="node">109</ID2> - </child> - <child ID="111" label="Fill in auto fields" layerID="1" - created="1479311744912" x="-228.27539" y="867.8467" - width="100.0" height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dda878ec0a80026548592b89f2f02ff</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="112" layerID="1" created="1479311744913" x="-204.52672" - y="826.3059" width="21.308167" height="42.04071" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#000000</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dda878ec0a80026548592b8274c2ea3</URIString> - <point1 x="-204.02672" y="826.80597"/> - <point2 x="-183.71855" y="867.8467"/> - <ID1 xsi:type="node">107</ID1> - <ID2 xsi:type="node">111</ID2> - </child> - <child ID="113" label="From path" layerID="1" - created="1479311761209" x="-286.06268" y="918.62933" - width="67.0" height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dda878ec0a80026548592b8a59d8be9</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="114" layerID="1" created="1479311761209" x="-236.97136" - y="889.3467" width="43.104645" height="29.782654" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#000000</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dda878ec0a80026548592b86e86d9d7</URIString> - <point1 x="-194.36671" y="889.8467"/> - <point2 x="-236.47136" y="918.62933"/> - <ID1 xsi:type="node">111</ID1> - <ID2 xsi:type="node">113</ID2> - </child> - <child ID="115" label="From count(path)" layerID="1" - created="1479311769963" x="-209.88853" y="920.3805" - width="105.0" height="22.0" strokeWidth="1.0" autoSized="true" xsi:type="node"> - <fillColor>#F2AE45</fillColor> - <strokeColor>#776D6D</strokeColor> - <textColor>#000000</textColor> - <font>Arial-plain-12</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dda878fc0a80026548592b8d8c09cc8</URIString> - <shape arcwidth="20.0" archeight="20.0" xsi:type="roundRect"/> - </child> - <child ID="116" layerID="1" created="1479311769964" x="-174.40192" - y="889.3467" width="13.139893" height="31.533813" - strokeWidth="1.0" autoSized="false" controlCount="0" - arrowState="2" xsi:type="link"> - <strokeColor>#000000</strokeColor> - <textColor>#404040</textColor> - <font>Arial-plain-11</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dda878fc0a80026548592b84916a321</URIString> - <point1 x="-173.90192" y="889.8467"/> - <point2 x="-161.76202" y="920.3805"/> - <ID1 xsi:type="node">111</ID1> - <ID2 xsi:type="node">115</ID2> - </child> - <layer ID="1" label="Layer 1" created="1479309847607" x="0.0" - y="0.0" width="1.4E-45" height="1.4E-45" strokeWidth="0.0" autoSized="false"> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b15c0a80026548592b8d2f3fee2</URIString> - </layer> - <userZoom>1.2621478010021852</userZoom> - <userOrigin x="-650.3251" y="259.74835"/> - <presentationBackground>#FFFFFF</presentationBackground> - <PathwayList currentPathway="0" revealerIndex="-1"> - <pathway ID="0" label="Chemin sans nom" created="1479309847603" - x="0.0" y="0.0" width="1.4E-45" height="1.4E-45" - strokeWidth="0.0" autoSized="false" currentIndex="-1" open="true"> - <strokeColor>#B3993333</strokeColor> - <textColor>#000000</textColor> - <font>SansSerif-plain-14</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b16c0a80026548592b8204729d3</URIString> - <masterSlide ID="2" created="1479309847623" x="0.0" y="0.0" - width="800.0" height="600.0" locked="true" - strokeWidth="0.0" autoSized="false"> - <fillColor>#000000</fillColor> - <strokeColor>#404040</strokeColor> - <textColor>#000000</textColor> - <font>SansSerif-plain-14</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b16c0a80026548592b817230376</URIString> - <titleStyle ID="3" label="Header" - created="1479309850047" x="329.0" y="174.5" - width="142.0" height="51.0" strokeWidth="0.0" - autoSized="true" isStyle="true" xsi:type="node"> - <strokeColor>#404040</strokeColor> - <textColor>#FFFFFF</textColor> - <font>Gill Sans-plain-36</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b17c0a80026548592b88a8fba25</URIString> - <shape xsi:type="rectangle"/> - </titleStyle> - <textStyle ID="4" label="Slide Text" - created="1479309850048" x="340.0" y="282.5" - width="120.0" height="35.0" strokeWidth="0.0" - autoSized="true" isStyle="true" xsi:type="node"> - <strokeColor>#404040</strokeColor> - <textColor>#FFFFFF</textColor> - <font>Gill Sans-plain-22</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b17c0a80026548592b8c426a9c8</URIString> - <shape xsi:type="rectangle"/> - </textStyle> - <linkStyle ID="5" label="Links" created="1479309850107" - x="372.5" y="385.0" width="55.0" height="30.0" - strokeWidth="0.0" autoSized="true" isStyle="true" xsi:type="node"> - <strokeColor>#404040</strokeColor> - <textColor>#B3BFE3</textColor> - <font>Gill Sans-plain-18</font> - <URIString>http://vue.tufts.edu/rdf/resource/6dbf6b18c0a80026548592b8ea0d19d7</URIString> - <shape xsi:type="rectangle"/> - </linkStyle> - </masterSlide> - </pathway> - </PathwayList> - <date>2016-11-16</date> - <modelVersion>6</modelVersion> - <saveLocation>/home/georges/phc/racket-packages/phc-graph</saveLocation> - <saveFile>/home/georges/phc/racket-packages/phc-graph/Graph-notes.vue</saveFile> -</LW-MAP> diff --git a/graph-info.hl.rkt b/graph-info.hl.rkt index f108af9..35691ff 100644 --- a/graph-info.hl.rkt +++ b/graph-info.hl.rkt @@ -1,43 +1,236 @@ -#lang racket +#lang hyper-literate racket #:no-auto-require -(provide (struct-out graph-info) - (struct-out node-info) - (struct-out field-info) - (struct-out rich-graph-info) - (struct-out rich-mapping-info)) +@require[scribble-math + scribble-enhanced/doc + "notations.rkt" + (for-label racket)] -(struct graph-info (name - multi-constructor - root - node-order - nodes)) -(struct node-info (constructor - predicate? - field-order - fields - promise-type - make-incomplete-type ;; may be removed later - incomplete-type - make-placeholder-type ;; may be removed later. - placeholder-type)) -(struct field-info (type - incomplete-type)) +@title[#:style (with-html5 manual-doc-style) + #:tag "graph-info" + #:tag-prefix "phc-graph/graph-info"]{Compile-time graph metadata} -(struct rich-graph-info (name - multi-constructor - root-node - root-mapping - node-order - nodes - mapping-order - mappings)) -(struct rich-mapping-info (constructor - ;predicate? - ;field-order - ;fields - with-promises-type - ;make-incomplete-type ;; may be removed later - ;incomplete-type - ;make-placeholder-type ;; may be removed later. - ;placeholder-type - )) \ No newline at end of file +@(chunks-toc-prefix + '("(lib phc-graph/scribblings/phc-graph-implementation.scrbl)" + "phc-graph/graph-info")) + +We define here the compile-time metadata describing a graph type. + +@section{Graph type information} + +@chunk[<graph-info> + (struct+/contract graph-info + ([name identifier?] + [tvars (listof identifier?)] + [root-node identifier?] + [node-order (listof identifier?)] + [nodes (hash/c symbol? node-info? #:immutable #t)] + [invariants (set/c invariant-info? #:kind 'immutable)]) + #:transparent + #:methods gen:custom-write + [(define write-proc (struct-printer 'graph-info))] + #:property prop:custom-print-quotable 'never)] + +@section{Graph builder information} + +@chunk[<graph-builder-info> + (struct+/contract graph-builder-info graph-info + ([name identifier?] + [tvars (listof identifier?)] + [root-node identifier?] + [node-order (listof identifier?)] + [nodes (hash/c symbol? node-info? #:immutable #t)] + [invariants (set/c invariant-info? #:kind 'immutable)]) + ([multi-constructor identifier?] + [root-mapping identifier?] + [mapping-order (listof identifier?)] + [mappings (hash/c symbol? mapping-info? #:immutable #t)] + [dependent-invariants (set/c dependent-invariant-info?)]) + #:transparent + #:methods gen:custom-write + [(define write-proc (struct-printer 'graph-builder-info))] + #:property prop:custom-print-quotable 'never)] + +@section{Node information} + +@chunk[<node-info> + (struct+/contract node-info + ([predicate? identifier?] + [field-order (listof identifier?)] + [fields (hash/c symbol? field-info? #:immutable #t)] + [promise-type identifier?] + [make-incomplete-type identifier?] + [incomplete-type identifier?]) + #:transparent + #:methods gen:custom-write + [(define write-proc (struct-printer 'node-info))] + #:property prop:custom-print-quotable 'never)] + +@section{Field information} + +A field has a type. + +@chunk[<field-info> + (struct+/contract field-info + ([type identifier?]) + #:transparent + #:methods gen:custom-write + [(define write-proc (struct-printer 'field-info))] + #:property prop:custom-print-quotable 'never)] + +@;[incomplete-type identifier?] + +@section{Invariant information} + +@chunk[<invariant-info> + (struct+/contract invariant-info + ([predicate identifier?] ; (→ RootNode Boolean : +witness-type) + [witness-type identifier?]) + #:transparent + #:methods gen:custom-write + [(define write-proc (struct-printer 'invariant-info))] + #:property prop:custom-print-quotable 'never)] + +@section{Dependent invariant information} + +The invariants described in the previous section assert properties of a graph +instance in isolation. It is however desirable to also describe invariants +which relate the old and the new graph in a graph transformation. + +@chunk[<dependent-invariant-info> + (struct+/contract dependent-invariant-info + ([checker identifier?] ; (→ RootMappingArguments… NewGraphRoot Boolean) + [name identifier?]) + #:transparent + #:methods gen:custom-write + [(define write-proc (struct-printer 'dependent-invariant-info))] + #:property prop:custom-print-quotable 'never)] + +@section{Mapping information} + +@chunk[<mapping-info> + (struct+/contract mapping-info + ([mapping-function identifier?] + [with-promises-type identifier?] + [make-placeholder-type identifier?] + [placeholder-type identifier?]) + #:transparent + #:methods gen:custom-write + [(define write-proc (struct-printer 'mapping-info))] + #:property prop:custom-print-quotable 'never)] + +@section{Printing} + +It is much easier to debug graph information if it is free from the visual +clutter of printed syntax objects (which waste most of the screen real estate +printing @tt{#<syntax:/path/to/file}, when the interesting part is the +contents of the syntax object). + +We therefore pre-process the fields, transforming syntax objects into regular +data. + +@chunk[<printer> + (define (to-datum v) + (syntax->datum (datum->syntax #f v))) + + (define (struct-printer2 ctor) + (make-constructor-style-printer + (λ (v) ctor) + (λ (v) (map to-datum (struct->list v))))) + + (define ((struct-printer ctor) st port mode) + (match-define (vector name fields ...) (struct->vector st)) + (define-values (info skipped?) (struct-info st)) + (define-values (-short-name _2 _3 _4 _5 _6 _7 _8) + (struct-type-info info)) + (define short-name (or ctor -short-name)) + (define (to-datum v) + (syntax->datum (datum->syntax #f v))) + (case mode + [(#t) + (display "#(~#t~" port) + (display name port) + (for-each (λ (f) + (display " " port) + (write (to-datum f) port)) + fields) + (display ")" port)] + [(#f) + (display "#(~#f~" port) + (display name port) + (for-each (λ (f) + (display " " port) + (display (to-datum f) port)) + fields) + (display ")" port)] + [(0) + (display "(" port) + (display short-name port) + (for-each (λ (f) + (display " " port) + ;; Circumvent the undocumented(?) autodetection of + ;; print which changes the behaviour if objects which + ;; are not eq? to the original fields are directly + ;; printed to the port. + (let ([str (with-output-to-string + (λ () + (print (to-datum f) (current-output-port) 0)))]) + (display (string-append str " ") port))) + fields) + (display ")" port)] + [(1) + (display "#(" port) + (display name port) + (for-each (λ (f) + (display " " port) + (display + ;; Circumvent the undocumented(?) autodetection of + ;; print which changes the behaviour if objects which + ;; are not eq? to the original fields are directly + ;; printed to the port. + #;(with-output-to-string + (λ () + (print (to-datum f) (current-output-port) 1))) + "abab" + port)) + fields) + (display ")" port)]))] + +@CHUNK[<*> + (require phc-toolkit/untyped + racket/struct + (for-syntax phc-toolkit/untyped + syntax/parse + syntax/parse/experimental/template)) + (define-syntax/parse + (struct+/contract name {~optional parent} + {~optional ([parent-field parent-contract] ...)} + ([field contract] ...) + {~optional {~and transparent #:transparent}} + (~and {~seq methods+props ...} + (~seq (~maybe #:methods + {~literal gen:custom-write} + _) + (~maybe #:property + {~literal prop:custom-print-quotable} + _)))) + (quasisyntax/top-loc this-syntax + #,(template + (begin + (struct name (?? parent) (field ...) + (?? transparent) + methods+props ...) + (provide (contract-out (struct (?? (name parent) name) + ((?? (?@ [parent-field parent-contract] + ...)) + [field contract] + ...)))))))) + + <printer> + + <field-info> + <node-info> + <invariant-info> + <dependent-invariant-info> + <graph-info> + <mapping-info> + <graph-builder-info>] diff --git a/graph-type.hl.rkt b/graph-type.hl.rkt new file mode 100644 index 0000000..a6b463d --- /dev/null +++ b/graph-type.hl.rkt @@ -0,0 +1,91 @@ +#lang hyper-literate typed/racket #:no-auto-require + +@require[scribble-math + scribble-enhanced/doc + "notations.rkt" + (for-label racket)] + +@title[#:style (with-html5 manual-doc-style) + #:tag "graph-type" + #:tag-prefix "phc-graph/graph-type"]{Declaring graph types} + +@(chunks-toc-prefix + '("(lib phc-graph/scribblings/phc-graph-implementation.scrbl)" + "phc-graph/graph-type")) + +@CHUNK[<define-graph-type> + (begin-for-syntax + (define-syntax-class signature + #:datum-literals (∈ ∋ ≡ ≢ ∉) + #:literals (:) + (pattern (name + {~maybe #:∀ (tvar …)} + (~and {~seq [nodeᵢ:id [fieldᵢⱼ:id : τ] …] …} + {~seq [root-node . _] _ …}) + {~seq #:invariant a {~and op {~or ∈ ∋ ≡ ≢ ∉}} b} … + {~seq #:invariant p} …)))) + + (define-syntax/parse (define-graph-type . :signature) + (define gi <graph-info>) + (local-require racket/pretty) + (pretty-print gi (current-output-port) 0) + #`(begin + (define-syntax name #,gi)))] + +@chunk[<graph-info> + (graph-info #'name + (syntax->list (if (attribute tvar) #'(tvar …) #'())) + #'root-node + (syntax->list #'(nodeᵢ …)) + (make-immutable-hash + (map cons + (stx-map syntax-e #'(nodeᵢ …)) + (stx-map (λ/syntax-case (nodeᵢ [fieldᵢⱼ τᵢⱼ] …) () + <node-info>) + #'([nodeᵢ [fieldᵢⱼ τᵢⱼ] …] …)))) + (list->set + (append + (stx-map (λ/syntax-case (op a b) () <invariant-info-op>) + #'([op a b] …)) + (stx-map (λ/syntax-case p () <invariant-info-p>) + #'(p …)))))] + +@chunk[<node-info> + (node-info (meta-struct-predicate + (check-remembered-node! #'(nodeᵢ fieldᵢⱼ …))) + (syntax->list #'(fieldᵢⱼ …)) + (make-immutable-hash + (map cons + (stx-map syntax-e #'(fieldᵢⱼ …)) + (stx-map (λ/syntax-case (fieldᵢⱼ τᵢⱼ) () + <field-info>) + #'([fieldᵢⱼ τᵢⱼ] …)))) + (check-remembered-node! #'(nodeᵢ fieldᵢⱼ …)) + (meta-struct-constructor + (check-remembered-tagged! #'(node-incompleteᵢ fieldᵢⱼ …))) + (check-remembered-tagged! #'(node-incompleteᵢ fieldᵢⱼ …)))] + +@chunk[<field-info> + (field-info #'τᵢⱼ)] + +@chunk[<invariant-info-op> + (invariant-info #'predicateTODO + #'witnessTODO)] + +@chunk[<invariant-info-p> + (invariant-info #'predicateTODO + #'witnessTODO)] + +@chunk[<*> + (require racket/require + phc-toolkit + (lib "phc-adt/tagged-structure-low-level.hl.rkt") + (for-syntax "graph-info.hl.rkt" + phc-toolkit/untyped + (subtract-in syntax/parse phc-graph/subtemplate) + racket/set + phc-graph/subtemplate)) + + (provide define-graph-type) + + <define-graph-type>] \ No newline at end of file diff --git a/graph.hl.rkt b/graph.hl.rkt index 792d757..649deb7 100644 --- a/graph.hl.rkt +++ b/graph.hl.rkt @@ -1,5 +1,6 @@ #lang hyper-literate typed/racket/base #:no-auto-require -@(require racket/require +@(require scribble-math + racket/require scribble-enhanced/doc racket/require hyper-literate @@ -20,6 +21,15 @@ (require (for-label (submod "..")))) @doc-lib-setup +@title[#:style (with-html5 manual-doc-style) + #:tag "graph-impl" + #:tag-prefix "phc-graph/graph-impl"]{Implementation of the graph macro} + +@(chunks-toc-prefix + '("(lib phc-graph/scribblings/phc-graph-implementation.scrbl)" + "phc-graph/graph-impl")) + + @chunk[<graph> (define-syntax define-graph (syntax-parser diff --git a/scribblings/phc-graph-implementation.scrbl b/scribblings/phc-graph-implementation.scrbl index fd383dd..6c32fec 100644 --- a/scribblings/phc-graph-implementation.scrbl +++ b/scribblings/phc-graph-implementation.scrbl @@ -13,4 +13,7 @@ the @other-doc['(lib "phc-graph/scribblings/phc-graph.scrbl")] document. @include-section[(submod "../traversal.hl.rkt" doc)] @include-section[(submod "../flexible-with.hl.rkt" doc)] -@include-section[(submod "../invariants-phantom.hl.rkt" doc)] \ No newline at end of file +@include-section[(submod "../invariants-phantom.hl.rkt" doc)] +@include-section[(submod "../graph-info.hl.rkt" doc)] +@include-section[(submod "../graph-type.hl.rkt" doc)] +@include-section[(submod "../graph.hl.rkt" doc)] \ No newline at end of file diff --git a/test/adt-pre-declarations.rkt b/test/adt-pre-declarations.rkt index e2d73e5..a8ac74a 100644 --- a/test/adt-pre-declarations.rkt +++ b/test/adt-pre-declarations.rkt @@ -2,3 +2,11 @@ (remembered! tagged-structure (tg a b)) (remembered! tagged-structure (tg a c)) (remembered! tagged-structure (t0)) +(remembered! tagged-structure (City citizens name streets)) +(remembered! tagged-structure (Street houses name)) +(remembered! tagged-structure (House owner)) +(remembered! tagged-structure (Person name)) +(remembered! tagged-structure (node-incompleteᵢ citizens name streets)) +(remembered! tagged-structure (node-incompleteᵢ houses name)) +(remembered! tagged-structure (node-incompleteᵢ owner)) +(remembered! tagged-structure (node-incompleteᵢ name)) diff --git a/test/test-graph-type.rkt b/test/test-graph-type.rkt new file mode 100644 index 0000000..6a08b80 --- /dev/null +++ b/test/test-graph-type.rkt @@ -0,0 +1,16 @@ +#lang typed/racket + +(require phc-adt + (lib "phc-graph/graph-type.hl.rkt")) +(adt-init) + +(define-graph-type g1 + [City [name : String] + [streets : (Listof Street)] + [citizens : (Listof Person)]] + [Street [name : String] + [houses : (Listof House)]] + [House [owner : Person]] + [Person [name : String]] + #:invariant City.citizens._ ∈ City.streets._.houses._.owner + #:invariant City.citizens._ ∋ City.streets._.houses._.owner) \ No newline at end of file