[openmp] [mlir] [libunwind] [clang-tools-extra] [lld] [llvm] [lldb] [compiler-rt] [libclc] [clang] [flang] [libcxx] [ocaml] Fixed typo error about set_module_identifier in llvm ocaml binding (PR #77479)

via cfe-commits cfe-commits at lists.llvm.org
Tue Jan 9 18:23:57 PST 2024


https://github.com/Yujinmon updated https://github.com/llvm/llvm-project/pull/77479

>From b5586e9935d30a587323699aac2213bae5d14174 Mon Sep 17 00:00:00 2001
From: Yujin <78896558+Yujinmon at users.noreply.github.com>
Date: Tue, 9 Jan 2024 23:14:52 +0900
Subject: [PATCH 1/3] fixed typo error about set_module_identifier

---
 llvm/bindings/ocaml/llvm/llvm.mli | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/llvm/bindings/ocaml/llvm/llvm.mli b/llvm/bindings/ocaml/llvm/llvm.mli
index e0febb79a2b61d..d5600698df2446 100644
--- a/llvm/bindings/ocaml/llvm/llvm.mli
+++ b/llvm/bindings/ocaml/llvm/llvm.mli
@@ -549,7 +549,7 @@ val get_module_identifier : llmodule -> string
 
 (** [set_module_identifier m id] sets the module identifier of [m]
     to [id]. See the method [llvm::Module::setModuleIdentifier] *)
-val set_module_identifer : llmodule -> string -> unit
+val set_module_identifier : llmodule -> string -> unit
 
 (** [get_module_flag m k] Return the corresponding value if key [k] appears in
     the module flags of [m], otherwise return None

>From 22818768a2977ae689166de2cc1b109f201673f9 Mon Sep 17 00:00:00 2001
From: Yujin <78896558+Yujinmon at users.noreply.github.com>
Date: Tue, 9 Jan 2024 23:19:25 +0900
Subject: [PATCH 2/3] fixed typo error about set_module_identifier in llvm.ml

---
 llvm/bindings/ocaml/llvm/llvm.ml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/llvm/bindings/ocaml/llvm/llvm.ml b/llvm/bindings/ocaml/llvm/llvm.ml
index 057798fc0cea2d..d83f737843b564 100644
--- a/llvm/bindings/ocaml/llvm/llvm.ml
+++ b/llvm/bindings/ocaml/llvm/llvm.ml
@@ -446,7 +446,7 @@ external module_context : llmodule -> llcontext = "llvm_get_module_context"
 external get_module_identifier : llmodule -> string
                                = "llvm_get_module_identifier"
 
-external set_module_identifer : llmodule -> string -> unit
+external set_module_identifier : llmodule -> string -> unit
                               = "llvm_set_module_identifier"
 
 external get_module_flag : llmodule -> string -> llmetadata option

>From a9b34c4e3916bb2da65f59bd57617d23f3b4ddfd Mon Sep 17 00:00:00 2001
From: Yujin <78896558+Yujinmon at users.noreply.github.com>
Date: Wed, 10 Jan 2024 11:23:48 +0900
Subject: [PATCH 3/3] fixed typo error "set_module_identifer ->
 set_module_identifier" in llvm core.ml

---
 llvm/test/Bindings/OCaml/core.ml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/llvm/test/Bindings/OCaml/core.ml b/llvm/test/Bindings/OCaml/core.ml
index a9abc9d17fe46e..c846d54aaaae75 100644
--- a/llvm/test/Bindings/OCaml/core.ml
+++ b/llvm/test/Bindings/OCaml/core.ml
@@ -523,7 +523,7 @@ let test_global_variables () =
     let m = create_module context "temp" in
 
     insist (get_module_identifier m = "temp");
-    set_module_identifer m "temp2";
+    set_module_identifier m "temp2";
     insist (get_module_identifier m = "temp2");
 
     insist (At_end m = global_begin m);



More information about the cfe-commits mailing list