From d4f6105e908d32e8ce1a2cdd96c641c2a9b4c3fb Mon Sep 17 00:00:00 2001 From: Your Name Date: Tue, 12 Nov 2024 14:13:51 -0500 Subject: [PATCH] Haddock fixes --- macaw-dump/src/Data/Macaw/Dump/Discover.hs | 11 +++++------ symbolic/src/Data/Macaw/Symbolic/Testing.hs | 9 +++++---- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/macaw-dump/src/Data/Macaw/Dump/Discover.hs b/macaw-dump/src/Data/Macaw/Dump/Discover.hs index 604e7f14..a6c229dc 100644 --- a/macaw-dump/src/Data/Macaw/Dump/Discover.hs +++ b/macaw-dump/src/Data/Macaw/Dump/Discover.hs @@ -52,12 +52,11 @@ instance X.Exception DiscoverException -- | Convert machine addresses into What4 positions. -- --- When possible, we map to the structured 'WPL.BinaryPos' type. However, some --- 'MM.MemSegmentOff' cannot be mapped to an absolute position (e.g., some --- addresses from shared libraries are in non-trivial segments). In those cases, --- we map to the unstructured 'WPL.Others' with a sufficiently descriptive string. --- --- TODO: import from `Testing` +-- When possible, we map to the structured 'WPL.BinaryPos' type. However, +-- some 'MM.MemSegmentOff' values cannot be mapped to an absolute position +-- (e.g., some addresses from shared libraries are in non-trivial segments). +-- In those cases, we map to the unstructured 'WPL.Others' with a sufficiently +-- descriptive string. posFn :: (MM.MemWidth w) => Text.Text -> MM.MemSegmentOff w -> WPL.Position posFn binaryName segOff = case MM.segoffAsAbsoluteAddr segOff of diff --git a/symbolic/src/Data/Macaw/Symbolic/Testing.hs b/symbolic/src/Data/Macaw/Symbolic/Testing.hs index 628836da..eadb4e04 100644 --- a/symbolic/src/Data/Macaw/Symbolic/Testing.hs +++ b/symbolic/src/Data/Macaw/Symbolic/Testing.hs @@ -113,10 +113,11 @@ instance X.Exception TestingException -- | Convert machine addresses into Crucible positions. -- --- When possible, we map to the structured 'WPL.BinaryPos' type. However, some --- 'MM.MemSegmentOff' cannot be mapped to an absolute position (e.g., some --- addresses from shared libraries are in non-trivial segments). In those cases, --- we map to the unstructured 'WPL.Others' with a sufficiently descriptive string. +-- When possible, we map to the structured 'WPL.BinaryPos' type. However, +-- some 'MM.MemSegmentOff' values cannot be mapped to an absolute position +-- (e.g., some addresses from shared libraries are in non-trivial segments). +-- In those cases, we map to the unstructured 'WPL.Others' with a sufficiently +-- descriptive string. posFn :: (MM.MemWidth w) => FilePath -> MM.MemSegmentOff w -> WPL.Position posFn binaryName segOff = case MM.segoffAsAbsoluteAddr segOff of