• Ankur Dave's avatar
    Fix call to Verifier::VerifyBuffer from BufferRef (#4124) · f8a964d2
    Ankur Dave authored
    3a1f7761 added a required identifier parameter
    to Verifier::VerifyBuffer but did not update the templated call site in
    BufferRef. This causes errors like the following when trying to instantiate the
    call site by calling BufferRef::Verify():
    
        include/flatbuffers/flatbuffers.h: In instantiation of ‘bool flatbuffers::BufferRef<T>::Verify() [with T = MyType]’:
        MyApp.cpp:16:3:   required from here
        include/flatbuffers/flatbuffers.h:1421:37: error: no matching function for call to ‘flatbuffers::Verifier::VerifyBuffer()’
             return verifier.VerifyBuffer<T>();
                                             ^
        include/flatbuffers/flatbuffers.h:1421:37: note: candidate is:
        include/flatbuffers/flatbuffers.h:1352:29: note: template<class T> bool flatbuffers::Verifier::VerifyBuffer(const char*)
           template<typename T> bool VerifyBuffer(const char *identifier) {
                                     ^
        include/flatbuffers/flatbuffers.h:1352:29: note:   template argument deduction/substitution failed:
        include/flatbuffers/flatbuffers.h:1421:37: note:   candidate expects 1 argument, 0 provided
             return verifier.VerifyBuffer<T>();
                                             ^
    
    This commit fixes the BufferRef call site by adding a nullptr argument.
    f8a964d2
Name
Last commit
Last update
CMake Loading commit data...
android Loading commit data...
biicode Loading commit data...
docs Loading commit data...
go Loading commit data...
grpc Loading commit data...
include/flatbuffers Loading commit data...
java/com/google/flatbuffers Loading commit data...
js Loading commit data...
net/FlatBuffers Loading commit data...
php Loading commit data...
python Loading commit data...
reflection Loading commit data...
samples Loading commit data...
src Loading commit data...
tests Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
.travis.yml Loading commit data...
CMakeLists.txt Loading commit data...
CONTRIBUTING.md Loading commit data...
ISSUE_TEMPLATE.md Loading commit data...
LICENSE.txt Loading commit data...
appveyor.yml Loading commit data...
biicode.conf Loading commit data...
composer.json Loading commit data...
pom.xml Loading commit data...
readme.md Loading commit data...