Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error: ‘pos_t’ is not a class or namespace #7

Open
tejasvi opened this issue Apr 9, 2019 · 0 comments
Open

error: ‘pos_t’ is not a class or namespace #7

tejasvi opened this issue Apr 9, 2019 · 0 comments

Comments

@tejasvi
Copy link

tejasvi commented Apr 9, 2019

p.cpp

#include "wnb/core/wordnet.hh"
#include "wnb/nltk_similarity.hh"

using namespace std;
using namespace wnb;

int main()
{
wordnet wn = wordnet("/usr/bin/", true);

vector synsets1 = wn.get_synsets("cat", 1);
vector synsets2 = wn.get_synsets("dog", 1);

nltk_similarity similarity(wn);
float d = similarity(synsets1[0], synsets2[0], 6);

}

Output

user@cclab-OptiPlex-5055-Ryzen-CPU:~$ gcc p.cpp
In file included from p.cpp:1:0:
wnb/core/wordnet.hh:89:74: error: ‘pos_t’ is not a class or namespace
std::vector get_synsets(const std::string& word, pos_t pos = pos_t::UNKNOWN);
^
p.cpp: In function ‘int main()’:
p.cpp:11:49: error: call to ‘std::vectorwnb::synset wnb::wordnet::get_synsets(const string&, wnb::pos_t)’ uses the default argument for parameter 2, which is not yet defined
vector synsets1 = wn.get_synsets("cat");
^
p.cpp:12:49: error: call to ‘std::vectorwnb::synset wnb::wordnet::get_synsets(const string&, wnb::pos_t)’ uses the default argument for parameter 2, which is not yet defined
vector synsets2 = wn.get_synsets("dog");
^

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant