Skip to content
Snippets Groups Projects
Commit 195bff88 authored by Adam Wardynski's avatar Adam Wardynski
Browse files

ParsingScope to pass around parser rules.

Sort of a comeback of an old idea. It's either this,
or adding a third parameter soon for lexicons.
I went with this as this makes it easier to add yet
another thing to toss around, if such need ever arises.
parent 88d3aef2
Branches
No related merge requests found
This diff is collapsed.
#ifndef LIBWCCL_PARSER_PARSINGSCOPE_H
#define LIBWCCL_PARSER_PARSINGSCOPE_H
#include <libwccl/variables.h>
namespace Wccl {
class ParsingScope
{
public:
ParsingScope(const Corpus2::Tagset& tagset)
: tagset_(tagset),
variables_()
{
}
const Corpus2::Tagset& tagset() {
return tagset_;
}
Variables& variables() {
return variables_;
}
private:
const Corpus2::Tagset& tagset_;
Variables variables_;
};
} /* end ns Wccl */
#endif // LIBWCCL_PARSER_PARSINGSCOPE_H
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment