summaryrefslogtreecommitdiff
path: root/lang/c/plugin.cpp
blob: 721cfc1987ff70eec031be67673f5d51db1be2a4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
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;
	}
}