Skip to content

error: call to non-static member function without an object argument #28

Description

@yurivict

clang-13 prints these errors:

In file included from /disk-samsung/freebsd-ports/cad/rsyn/work/rsyn-x-3855afb/x/src/x/nfl/NFLegal.cpp:25:
In file included from /disk-samsung/freebsd-ports/cad/rsyn/work/rsyn-x-3855afb/x/src/x/nfl/NFLegal.h:27:
/usr/include/c++/v1/deque:1954:35: error: call to non-static member function without an object argument
    allocator_type& __a = __base::__alloc();
                          ~~~~~~~~^~~~~~~
/disk-samsung/freebsd-ports/cad/rsyn/work/rsyn-x-3855afb/x/src/x/nfl/NFLegal.cpp:834:14: note: in instantiation of member function 'std::deque<NFL::TNode>::push_back' requested here
                        childreen.push_back(TNode());
                                  ^
In file included from /disk-samsung/freebsd-ports/cad/rsyn/work/rsyn-x-3855afb/x/src/x/nfl/NFLegal.cpp:25:
In file included from /disk-samsung/freebsd-ports/cad/rsyn/work/rsyn-x-3855afb/x/src/x/nfl/NFLegal.h:27:
/usr/include/c++/v1/deque:1954:35: error: '__alloc' is a protected member of 'std::__deque_base<NFL::TNode, std::allocator<NFL::TNode>>'
    allocator_type& __a = __base::__alloc();
                                  ^
/usr/include/c++/v1/deque:1042:53: note: declared protected here
    _LIBCPP_INLINE_VISIBILITY allocator_type&       __alloc()       {return __size_.second();}
                                                    ^
/usr/include/c++/v1/deque:1954:35: error: '__alloc' is a protected member of 'std::__deque_base<NFL::TNode, std::allocator<NFL::TNode>>'
    allocator_type& __a = __base::__alloc();
                                  ^
/usr/include/c++/v1/deque:1044:27: note: declared protected here
    const allocator_type& __alloc() const _NOEXCEPT {return __size_.second();}
                          ^
/usr/include/c++/v1/deque:1959:15: error: call to non-static member function without an object argument
    ++__base::size();
      ~~~~~~~~^~~~
/usr/include/c++/v1/deque:1959:15: error: 'size' is a protected member of 'std::__deque_base<NFL::TNode, std::allocator<NFL::TNode>>'
/usr/include/c++/v1/deque:1039:53: note: declared protected here
    _LIBCPP_INLINE_VISIBILITY size_type&            size()          {return __size_.first();}
                                                    ^
/usr/include/c++/v1/deque:1959:15: error: 'size' is a protected member of 'std::__deque_base<NFL::TNode, std::allocator<NFL::TNode>>'
    ++__base::size();
              ^
/usr/include/c++/v1/deque:1041:22: note: declared protected here
    const size_type& size() const _NOEXCEPT {return __size_.first();}
                     ^
/usr/include/c++/v1/deque:1507:40: error: invalid use of non-static data member '__start_'
        return __capacity() - (__base::__start_ + __base::size());
                               ~~~~~~~~^~~~~~~~
/usr/include/c++/v1/deque:1955:9: note: in instantiation of member function 'std::deque<NFL::TNode>::__back_spare' requested here
    if (__back_spare() == 0)
        ^

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions