MimIR
0.1
MimIR is my Intermediate Representation
Loading...
Searching...
No Matches
regex2nfa.h
Go to the documentation of this file.
1
#pragma once
2
3
#include <
automaton/nfa.h
>
4
5
#include "
mim/plug/regex/regex.h
"
6
7
/// You can dl::get this function.
8
/// @returns a raw pointer to automanton::NFA; use mim::regex::regex2nfa to pack it into a `std::unique_ptr`.
9
extern
"C"
MIM_EXPORT
automaton::NFA
*
regex2nfa
(
mim::Ref
regex);
10
11
namespace
mim::plug::regex
{
12
13
std::unique_ptr<automaton::NFA>
regex2nfa
(Ref regex);
14
15
inline
std::unique_ptr<automaton::NFA>
regex2nfa
(
decltype
(
::regex2nfa
)* fptr,
Ref
regex) {
16
return
std::unique_ptr<automaton::NFA>(fptr(regex), std::default_delete<automaton::NFA>());
17
}
18
19
}
// namespace mim::plug::regex
automaton::NFA
Definition
nfa.h:55
mim::Ref
Helper class to retrieve Infer::arg if present.
Definition
def.h:86
MIM_EXPORT
#define MIM_EXPORT
Definition
config.h:16
mim::plug::regex
The regex Plugin
Definition
lower_regex.h:5
mim::plug::regex::regex2nfa
std::unique_ptr< automaton::NFA > regex2nfa(Ref regex)
Definition
regex2nfa.cpp:89
nfa.h
regex2nfa
MIM_EXPORT automaton::NFA * regex2nfa(mim::Ref regex)
You can dl::get this function.
Definition
regex2nfa.cpp:97
regex.h
include
mim
plug
regex
regex2nfa.h
Generated by
1.12.0