Skip to content

Commit

Permalink
Add comment explaining LLVMModule datatype invariant.
Browse files Browse the repository at this point in the history
  • Loading branch information
Brian Huffman committed Jan 10, 2020
1 parent 8ec8e1a commit 3abe2ef
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/SAWScript/Crucible/LLVM/MethodSpecIR.hs
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,11 @@ data LLVMModule arch =
, _modAST :: L.Module
, _modTrans :: CL.ModuleTranslation arch
}
-- NOTE: Type 'LLVMModule' is exported as an abstract type, and we
-- maintain the invariant that the 'FilePath', 'Module', and
-- 'ModuleTranslation' fields are all consistent with each other;
-- 'loadLLVMModule' is the only function that is allowed to create
-- values of type 'LLVMModule'.

-- | The file path that the LLVM module was loaded from.
modFilePath :: LLVMModule arch -> FilePath
Expand Down

0 comments on commit 3abe2ef

Please sign in to comment.