diff options
Diffstat (limited to 'docs')
-rw-r--r-- | docs/ClangPlugins.rst | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/docs/ClangPlugins.rst b/docs/ClangPlugins.rst index 9a5bc14213..1aeff62e2f 100644 --- a/docs/ClangPlugins.rst +++ b/docs/ClangPlugins.rst @@ -37,11 +37,14 @@ Registering a plugin ==================== A plugin is loaded from a dynamic library at runtime by the compiler. To -register a plugin in a library, use ``FrontendPluginRegistry::Add<>``: +register a plugin in a library, use ``FrontendPluginRegistry::Add<>``. +On Windows, you also need to export your plugin registry using +``LLVM_EXPORT_REGISTRY``. Here is an example: .. code-block:: c++ static FrontendPluginRegistry::Add<MyPlugin> X("my-plugin-name", "my plugin description"); + LLVM_EXPORT_REGISTRY(FrontendPluginRegistry) Putting it all together ======================= |