diff options
Diffstat (limited to 'lang/c/plugin.cpp')
| -rw-r--r-- | lang/c/plugin.cpp | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/lang/c/plugin.cpp b/lang/c/plugin.cpp new file mode 100644 index 00000000..721cfc19 --- /dev/null +++ b/lang/c/plugin.cpp @@ -0,0 +1,30 @@ +#include "binaryninjaapi.h" +#include "pseudoc.h" +#include "pseudoobjc.h" + +using namespace BinaryNinja; + +extern "C" +{ + BN_DECLARE_CORE_ABI_VERSION + +#ifndef DEMO_EDITION + BINARYNINJAPLUGIN void CorePluginDependencies() + { + } +#endif + +#ifdef DEMO_EDITION + bool PseudoCPluginInit() +#else + BINARYNINJAPLUGIN bool CorePluginInit() +#endif + { + LanguageRepresentationFunctionType* type = new PseudoCFunctionType(); + LanguageRepresentationFunctionType::Register(type); + + type = new PseudoObjCFunctionType(); + LanguageRepresentationFunctionType::Register(type); + return true; + } +} |
