Ссылка на «кортеж» в SESHAT неоднозначна

Я пытался построить Seshat(Рукописный синтаксический анализатор математических выражений). И у меня есть ошибка, как это ниже:

In file included from rnnlib4seshat/DataSequence.hpp:26:0,
from symrec.h:30,
from production.h:28,
from hypothesis.h:30,
from cellcyk.h:24,
from tablecyk.h:26,
from sample.h:27,
from symfeatures.h:32,
from symfeatures.cc:18:
rnnlib4seshat/Helpers.hpp:131:15: error: reference to ‘tuple’ is ambiguous
typedef const tuple<real_t&, real_t&, real_t&, real_t&>& TDDDD;
^~~~~

У меня нет большого опыта в программировании на Си. Пожалуйста, помогите мне решить эту проблему.

Обновление: это часть файла Helpers.hpp

#ifndef _INCLUDED_Helpers_h
#define _INCLUDED_Helpers_h

#include <boost/date_time.hpp>
#include <boost/date_time/local_time/local_time.hpp>
#include <boost/assign/std/vector.hpp>
#include <boost/iterator/zip_iterator.hpp>
#include <boost/foreach.hpp>
#include <boost/math/distributions.hpp>
#include <boost/assign/list_of.hpp>
#include <boost/range/irange.hpp>
#include <math.h>
#include <numeric>
#include <utility>
#include <iostream>
#include <iomanip>
#include <fstream>
#include <string>
#include <sstream>
#include <list>
#include <set>
#include <algorithm>
#include <iterator>
#include <map>
#include <assert.h>
#include "Log.hpp"
using namespace std;
using namespace boost;
using namespace boost::assign;
using namespace boost::posix_time;
using namespace boost::gregorian;

#define LOOP BOOST_FOREACH
#define LOOP_BACK BOOST_REVERSE_FOREACH
#define DO(x, y) BOOST_FOREACH(BOOST_TYPEOF(*((y).begin()))& (x), (y))
#define DOC(x, y) BOOST_FOREACH(const BOOST_TYPEOF(*((y).begin()))& (x), (y))
#define OD(x, y) BOOST_REVERSE_FOREACH(BOOST_TYPEOF(*((y).begin()))& (x), (y))
#define COD(x, y) BOOST_REVERSE_FOREACH(const BOOST_TYPEOF(*((y).begin()))& (x), (y))
#define REPEAT(n) for(int REPEAT_VARn = 0; REPEAT_VARn < (n); ++REPEAT_VARn)
#define FROM(i, m, n) for(int (i) = (m); (i) < (n); ++(i))
#define MORF(i, m, n) for(int (i) = (n)-1; (i) >= (m); --(i))
#define FOR(i, n) for(int (i) = 0; (i) < (n); ++(i))
#define ROF(i, n) for(int (i) = (n)-1; (i) >= 0; --(i))

//#define FLOAT_REALS

#ifdef FLOAT_REALS
typedef float real_t;
#else
typedef double real_t;
#endif

....
line 131 begin here
typedef const tuple<real_t&, real_t&, real_t&, real_t&>& TDDDD;
typedef const tuple<real_t&, real_t&, real_t&, real_t&, real_t&>& TDDDDD;
typedef const tuple<real_t&, real_t&, real_t&>& TDDD;
typedef const tuple<real_t&, real_t&, int&>& TDDI;
typedef const tuple<real_t&, real_t&, real_t&>& TDDF;
typedef const tuple<real_t&, real_t&, real_t>& TDDCF;
typedef const tuple<real_t&, real_t&>& TDD;
typedef const tuple<int, string>& TIS;
typedef const tuple<int, int>& TII;
typedef const tuple<int, real_t>& TID;
typedef const tuple<int, set<int>&>& TISETI;
typedef const tuple<int&, bool, int>& TIBI;
typedef const tuple<real_t, Log<real_t>& >& TDL;
typedef const tuple<real_t&, Log<real_t>, Log<real_t> >& TDLL;
typedef Log<real_t> prob_t;

//global variables
....

Я обнаружил, что похожая проблема была отправлена ​​на вкладку «Проблемы» этого проекта (https://github.com/falvaro/seshat/issues/16). Но нет ответа на это. Похоже, что автор больше не поддерживает этот проект. Так что мне действительно нужна твоя помощь. Большое спасибо и извините за мой плохой английский.

0

Решение

Вот копия оригинального репозитория Github, включая модификации, позволяющие компилировать современный копилер.

https://github.com/LBrunswic/Seshat

1

Другие решения

Других решений пока нет …

По вопросам рекламы ammmcru@yandex.ru
Adblock
detector