Ошибка Clang: используйте ключевое слово template, чтобы рассматривать X как зависимое имя шаблона. - PullRequest
0 голосов
/ 04 мая 2018

Я использую Clang 3.4.2. Глядя на решение, представленное здесь:

Совместно используемая память Векторы в бусте с

Строка:

typedef basic_string<char, std::char_traits<char>, salloc::rebind<char>::other> shared_string;

выдает ошибку:

error: use 'template' keyword to treat 'rebind' as a dependent template name
    typedef basic_string<char, std::char_traits<char>, salloc::rebind<char>::other> shared_string;

Я пытался:

typedef basic_string<char, std::char_traits<char>, salloc::template rebind<char>::other> shared_string;

и даже:

typedef basic_string<char, std::char_traits<char>, template salloc::rebind<char>::other> shared_string;

но я все еще получаю ошибку.

Может кто-нибудь помочь мне поправить меня?

...