Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

The kit Desktop Qt 5.7.1 MSVC2013 64bit has configuration issues which might be the root cause for this problem. When executing step "Make"



  • I tried the following boost example:
    https://www.boost.org/doc/libs/1_41_0/libs/regex/example/snippets/captures_example.cpp

    0_1527582160170_ckckck.png
    but I got some errors
    Compile output:

    11:48:53: Running steps for project test_b...
    11:48:53: Configuration unchanged, skipping qmake step.
    11:48:53: Starting: "C:\Qt\Qt5.7.1\Tools\QtCreator\bin\jom.exe" 
    	C:\Qt\Qt5.7.1\Tools\QtCreator\bin\jom.exe -f Makefile.Debug
    	cl -c -nologo -Zc:wchar_t -FS -Zi -MDd -GR -W3 -w34100 -w34189 -w44996 -EHsc /Fddebug\test_b.vc.pdb -DUNICODE -DWIN32 -DWIN64 -DQT_DEPRECATED_WARNINGS -DQT_QML_DEBUG -DQT_CORE_LIB -I..\test_b -I. -IC:\local\boost_1_59_0 -IC:\Qt\Qt5.7.1\5.7\msvc2013_64\include -IC:\Qt\Qt5.7.1\5.7\msvc2013_64\include\QtCore -Idebug -IC:\Qt\Qt5.7.1\5.7\msvc2013_64\mkspecs\win32-msvc2013 -Fodebug\ @C:\Users\Nourhan\AppData\Local\Temp\main.obj.6392.203.jom
    main.cpp
    ..\test_b\main.cpp(9) : error C3861: 'print_captures': identifier not found
    ..\test_b\main.cpp(11) : error C3861: 'print_captures': identifier not found
    ..\test_b\main.cpp(12) : error C3861: 'print_captures': identifier not found
    ..\test_b\main.cpp(13) : error C3861: 'print_captures': identifier not found
    ..\test_b\main.cpp(14) : error C3861: 'print_captures': identifier not found
    ..\test_b\main.cpp(15) : error C3861: 'print_captures': identifier not found
    ..\test_b\main.cpp(16) : error C3861: 'print_captures': identifier not found
    ..\test_b\main.cpp(17) : error C3861: 'print_captures': identifier not found
    ..\test_b\main.cpp(38) : error C2039: 'captures' : is not a member of 'boost::match_results<std::_String_const_iterator<std::_String_val<std::_Simple_types<char>>>,std::allocator<_Ty>>'
            with
            [
                _Ty=boost::sub_match<std::_String_const_iterator<std::_String_val<std::_Simple_types<char>>>>
            ]
    ..\test_b\main.cpp(38) : error C2228: left of '.size' must have class/struct/union
    ..\test_b\main.cpp(44) : error C2039: 'captures' : is not a member of 'boost::match_results<std::_String_const_iterator<std::_String_val<std::_Simple_types<char>>>,std::allocator<_Ty>>'
            with
            [
                _Ty=boost::sub_match<std::_String_const_iterator<std::_String_val<std::_Simple_types<char>>>>
            ]
    jom: C:\Users\Nourhan\Documents\qt\Debug\Makefile.Debug [debug\main.obj] Error 2
    jom: C:\Users\Nourhan\Documents\qt\Debug\Makefile [debug] Error 2
    11:48:59: The process "C:\Qt\Qt5.7.1\Tools\QtCreator\bin\jom.exe" exited with code 2.
    Error while building/deploying project test_b (kit: Desktop Qt 5.7.1 MSVC2013 64bit)
    The kit Desktop Qt 5.7.1 MSVC2013 64bit has configuration issues which might be the root cause for this problem.
    When executing step "Make"
    11:48:59: Elapsed time: 00:06.
    
    

    screenshot here
    I appreciate any help , thanks


  • Qt Champions 2017

    It is not a issue with Qt Configuration. Where is print_captures function defined ? Due to this it is getting into issue.



  • @dheerendra
    thanks to reply
    print_captures method defined in main.ccp after main method
    ![screenshot here](Uploading 100%)


  • Qt Champions 2017

    define the print_capture before the main method & check.


  • Lifetime Qt Champion

    Hi
    is there a reason you cant just use
    http://doc.qt.io/qt-5/qregularexpression.html ?



  • @dheerendra your answer solves some errors but still onces related to boost:

    C:\Users\Nourhan\Documents\qt\test_b\main.cpp:22: error: C2039: 'captures' : is not a member of 'boost::match_results<std::_String_const_iterator<std::_String_val<std::_Simple_types<char>>>,std::allocator<_Ty>>'
    with
    [
        _Ty=boost::sub_match<std::_String_const_iterator<std::_String_val<std::_Simple_types<char>>>>
    ]
    C:\Users\Nourhan\Documents\qt\test_b\main.cpp:22: error: C2039: 'captures' : is not a member of 'boost::match_results<std::_String_const_iterator<std::_String_val<std::_Simple_types<char>>>,std::allocator<_Ty>>'
    with
    [
        _Ty=boost::sub_match<std::_String_const_iterator<std::_String_val<std::_Simple_types<char>>>>
    ]
    

  • Qt Champions 2017

    It is boost library issue. Looks like you are not using the capture method of boost properly . Look at some examples of boost and fix your issue.


Log in to reply