From c933d1b474610e48d83f0b76d33739b162292cc7 Mon Sep 17 00:00:00 2001 From: lemastero Date: Thu, 14 Dec 2023 11:41:58 +0100 Subject: [PATCH] module header is proper Rust comment --- src/Agda/Compiler/Rust/Backend.hs | 2 +- test/Hello.rs | 2 +- test/RustBackendTest.hs | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Agda/Compiler/Rust/Backend.hs b/src/Agda/Compiler/Rust/Backend.hs index 92bb4ec..e8e838f 100644 --- a/src/Agda/Compiler/Rust/Backend.hs +++ b/src/Agda/Compiler/Rust/Backend.hs @@ -95,4 +95,4 @@ writeModule opts _ _ mName cdefs = do -- TODO and change to TopLevelModuleName -> String -- TODO ideally test using real file moduleHeader :: String -> String -moduleHeader mName = "*** module " <> mName <> " ***\n" \ No newline at end of file +moduleHeader mName = "// module " <> mName <> "\n" \ No newline at end of file diff --git a/test/Hello.rs b/test/Hello.rs index 1a65987..27b0771 100644 --- a/test/Hello.rs +++ b/test/Hello.rs @@ -1,4 +1,4 @@ -*** module test.Hello *** +// module test.Hello Bool = Datatype { dataPars = 0 dataIxs = 0 diff --git a/test/RustBackendTest.hs b/test/RustBackendTest.hs index bd7e018..a7294c1 100644 --- a/test/RustBackendTest.hs +++ b/test/RustBackendTest.hs @@ -15,7 +15,7 @@ testIsEnabled = TestCase testModuleHeader :: Test testModuleHeader = TestCase - (assertEqual "moduleHeader" (moduleHeader "foo") "*** module foo ***\n") + (assertEqual "moduleHeader" (moduleHeader "foo") "// module foo\n") tests :: Test tests = TestList [