Make the compile function plain C and take a JSON grammar

This commit is contained in:
Max Brunsfeld 2016-01-10 20:04:41 -08:00
parent b69e19c525
commit d4632ab9a9
54 changed files with 325 additions and 234 deletions

16
src/compiler/compile.h Normal file
View file

@ -0,0 +1,16 @@
#ifndef COMPILER_COMPILE_H_
#define COMPILER_COMPILE_H_
#include <string>
#include <utility>
#include "compiler/compile_error.h"
namespace tree_sitter {
struct Grammar;
std::pair<std::string, CompileError> compile(const Grammar &, std::string);
} // namespace tree_sitter
#endif // COMPILER_COMPILE_H_