Created formlink.py and test code.
authorDavid Anderson <davea42@earthlink.net>
Thu, 31 May 2012 16:34:42 +0000 (09:34 -0700)
committerDavid Anderson <davea42@earthlink.net>
Thu, 31 May 2012 16:34:42 +0000 (09:34 -0700)
dwarf5/tools/Makefile
dwarf5/tools/formlink.base [new file with mode: 0644]
dwarf5/tools/formlink.in [new file with mode: 0644]
dwarf5/tools/formlink.py [new file with mode: 0644]

index f05f92d..b2d9f64 100644 (file)
@@ -35,4 +35,8 @@ test:
        # checking for idempotence
        python attrlink.py attrlink.in.out
        diff attrlink.in.out.out attrlink.base
+       python formlink.py formlink.in
+       diff formlink.in.out formlink.base
+       python formlink.py formlink.in.out
+       diff formlink.in.out.out formlink.base
      
diff --git a/dwarf5/tools/formlink.base b/dwarf5/tools/formlink.base
new file mode 100644 (file)
index 0000000..a0879d0
--- /dev/null
@@ -0,0 +1,5 @@
+DW_AT_name
+DW_TAG_namespace
+\livelink{chap:DWFORMref2}{DW_FORM_ref2}
+
+\livelink{chap:DWFORMref4}{DW_FORM_ref4}
diff --git a/dwarf5/tools/formlink.in b/dwarf5/tools/formlink.in
new file mode 100644 (file)
index 0000000..d39d6c0
--- /dev/null
@@ -0,0 +1,5 @@
+DW_AT_name
+DW_TAG_namespace
+DW_FORM_ref2
+
+DW_FORM_ref4
diff --git a/dwarf5/tools/formlink.py b/dwarf5/tools/formlink.py
new file mode 100644 (file)
index 0000000..e28d9e5
--- /dev/null
@@ -0,0 +1,11 @@
+# Copyright 2012 DWARF Debugging Information Format Committee
+#
+# All DW_FORM_* entries not in {} are turned into \livelink.
+
+import sys
+import anylink
+
+if __name__ == '__main__':
+  anylink.read_args("DW_FORM_")
+
+