static/source/embindmaker/embindmaker.cxx |   49 +++++++++++++++---------------
 1 file changed, 25 insertions(+), 24 deletions(-)

New commits:
commit 2df1dcc324c67d2205f0ff86378f07e2eeddc1b2
Author:     Stephan Bergmann <stephan.bergm...@allotropia.de>
AuthorDate: Mon Jan 29 12:05:13 2024 +0100
Commit:     Stephan Bergmann <stephan.bergm...@allotropia.de>
CommitDate: Tue Jan 30 07:39:06 2024 +0100

    Some renaming of generated identifiers
    
    uno_Type_com$sun$star$... and uno_Reference_com$sun$star$...
    
    Change-Id: Ibc19f423a60c521c376172807b4d5a34cf0179a5
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/162696
    Tested-by: Jenkins
    Reviewed-by: Stephan Bergmann <stephan.bergm...@allotropia.de>

diff --git a/static/source/embindmaker/embindmaker.cxx 
b/static/source/embindmaker/embindmaker.cxx
index 0eb3bc684db5..b7c9b1a51eb2 100644
--- a/static/source/embindmaker/embindmaker.cxx
+++ b/static/source/embindmaker/embindmaker.cxx
@@ -455,8 +455,8 @@ void writeJsMap(std::ostream& out, Module const& module, 
std::string const& pref
         {
             out << ",
";
         }
-        out << prefix << "'" << ifc.copy(ifc.lastIndexOf('.') + 1) << "': 
instance." << jsName(ifc)
-            << "Ref";
+        out << prefix << "'" << ifc.copy(ifc.lastIndexOf('.') + 1) << "': 
instance.uno_Reference_"
+            << jsName(ifc);
         comma = true;
     }
     for (auto const & [ id, sub ] : module.modules)
@@ -544,30 +544,31 @@ SAL_IMPLEMENT_MAIN()
             cppOut << "static void __attribute__((noinline)) register" << n
                    << "() {
"
                       "    ::emscripten::class_<"
-                   << cppName(ifc) << ">(\"" << jsName(ifc) << "\")
";
+                   << cppName(ifc) << ">(\"uno_Type_" << jsName(ifc) << "\")
";
             dumpAttributes(cppOut, ifc, ifcEnt);
             dumpMethods(cppOut, mgr, ifc, ifcEnt, false);
-            cppOut << "        ;
"
-                      "    
::emscripten::class_<::com::sun::star::uno::Reference<"
-                   << cppName(ifc)
-                   << ">, 
::emscripten::base<::com::sun::star::uno::BaseReference>>(\""
-                   << jsName(ifc)
-                   << "Ref\")
"
-                      "        .constructor<>()
"
-                      "        
.constructor<::com::sun::star::uno::BaseReference, "
-                      "::com::sun::star::uno::UnoReference_Query>()
"
-                      "        .function(\"is\", 
&::com::sun::star::uno::Reference<"
-                   << cppName(ifc)
-                   << ">::is)
"
-                      "        .function(\"get\", 
&::com::sun::star::uno::Reference<"
-                   << cppName(ifc)
-                   << ">::get, ::emscripten::allow_raw_pointers())
"
-                      "        .function(\"set\", "
-                      
"::emscripten::select_overload<bool(::com::sun::star::uno::Any const "
-                      "&, "
-                      
"com::sun::star::uno::UnoReference_Query)>(&::com::sun::star::uno::"
-                      "Reference<"
-                   << cppName(ifc) << ">::set))
";
+            cppOut
+                << "        ;
"
+                   "    ::emscripten::class_<::com::sun::star::uno::Reference<"
+                << cppName(ifc)
+                << ">, 
::emscripten::base<::com::sun::star::uno::BaseReference>>(\"uno_Reference_"
+                << jsName(ifc)
+                << "\")
"
+                   "        .constructor<>()
"
+                   "        .constructor<::com::sun::star::uno::BaseReference, 
"
+                   "::com::sun::star::uno::UnoReference_Query>()
"
+                   "        .function(\"is\", 
&::com::sun::star::uno::Reference<"
+                << cppName(ifc)
+                << ">::is)
"
+                   "        .function(\"get\", 
&::com::sun::star::uno::Reference<"
+                << cppName(ifc)
+                << ">::get, ::emscripten::allow_raw_pointers())
"
+                   "        .function(\"set\", "
+                   
"::emscripten::select_overload<bool(::com::sun::star::uno::Any const "
+                   "&, "
+                   
"com::sun::star::uno::UnoReference_Query)>(&::com::sun::star::uno::"
+                   "Reference<"
+                << cppName(ifc) << ">::set))
";
             dumpAttributes(cppOut, ifc, ifcEnt);
             dumpMethods(cppOut, mgr, ifc, ifcEnt, true);
             cppOut << "        ;
"

Reply via email to