diff options
author | letouzey <letouzey@85f007b7-540e-0410-9357-904b9bb8a0f7> | 2011-03-07 15:37:55 +0000 |
---|---|---|
committer | letouzey <letouzey@85f007b7-540e-0410-9357-904b9bb8a0f7> | 2011-03-07 15:37:55 +0000 |
commit | 654f4e0f4dfae3073f8af5ccf54636f927191276 (patch) | |
tree | 67517f46e2f08d2c0a52b64bedab0f0ca16a395f | |
parent | 2d0293367d13ac8ef8c337ba1dd0085f83dc501b (diff) |
Extraction: fix printing of haskell modular names
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@13890 85f007b7-540e-0410-9357-904b9bb8a0f7
-rw-r--r-- | plugins/extraction/common.ml | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/plugins/extraction/common.ml b/plugins/extraction/common.ml index ad2f40063..8b0b5338a 100644 --- a/plugins/extraction/common.ml +++ b/plugins/extraction/common.ml @@ -512,8 +512,10 @@ let pp_ocaml_gen k mp rls olab = let pp_haskell_gen k mp rls = match rls with | [] -> assert false | s::rls' -> - (if base_mp mp <> top_visible_mp () then s ^ "." else "") ^ - (if upperkind k then "" else "_") ^ pseudo_qualify rls' + let str = pseudo_qualify rls' in + let str = if is_upper str && not (upperkind k) then ("_"^str) else str in + let prf = if base_mp mp <> top_visible_mp () then s ^ "." else "" in + prf ^ str (* Main name printing function for a reference *) |