bloomberg / bloomberg/rmqcpp

rmqcpp is using deprecated VC++17 features

Aperta
#53 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
C++
Stelle
106
Fork
32
Merge medio
9h 4m
PR unite (30g)
6

Descrizione

**Describe the bug**
Building a project that references rmqcpp gives errors related to deprecated features. I have to suppress the warnings to make it build successfully.

Error C4996 'std::raw_storage_iterator': warning STL4011: std::raw_storage_iterator is deprecated in C++17. Consider using the std::uninitialized_copy() family of algorithms instead. You can define _SILENCE_CXX17_RAW_STORAGE_ITERATOR_DEPRECATION_WARNING or _SILENCE_ALL_CXX17_DEPRECATION_WARNINGS to suppress this warning. rabbitMQStream_rmqcpp D:\source\repos\rabbitMQ_cppExample\rabbitMQStream_rmqcpp\vcpkg_installed\x64-windows\x64-windows\include\bsl_memory.h 106

Error C4996 'std::binary_negate': warning STL4008: std::not1(), std::not2(), std::unary_negate, and std::binary_negate are deprecated in C++17. They are superseded by std::not_fn(). You can define _SILENCE_CXX17_NEGATORS_DEPRECATION_WARNING or _SILENCE_ALL_CXX17_DEPRECATION_WARNINGS to suppress this warning. rabbitMQStream_rmqcpp D:\source\repos\rabbitMQ_cppExample\rabbitMQStream_rmqcpp\vcpkg_installed\x64-windows\x64-windows\include\bsl_functional.h 68

**To Reproduce**
Steps to reproduce the behavior:
1. In Visual Studio, Create a new console application (MSBuild)
2. Add vcpkg.json file to the project. Past the following: { "dependencies": ["rmqcpp"]}
3. enable vcpkg manifest mode: right-click on project in solution explorer, in Configuration Properties > vcpkg set "Use Vcpkg Manifest" to Yes.
4. Copy code from rmqcpp examples HelloWorld>producer.m.cpp to and replace the main function in the project.
5. Set C++ Language Standard : Configuration Properties > General> C++ Language Standard: ISO C++ 17 Standard
6. Compile Project.

**Expected behavior**
Error C4996 'std::raw_storage_iterator': warning STL4011: std::raw_storage_iterator is deprecated in C++17
Error C4996 'std::binary_negate': warning STL4008: std::not1(), std::not2(), std::unary_negate, and std::binary_negate are deprecated in C++17. They are superseded by std::not_fn().

**Screenshots**
![image](https://github.com/user-attachments/assets/65556dd3-79bf-4f1a-a2fa-cb3bfdb20dfb)

**Environment (please complete the following information):**
- Operating System and Version: Windows 11

Guida per i contributori

Apri la guida per i contributori

Direzione di ricerca

Riprodurre la compilazione in Visual Studio con un manifest vcpkg, C++17 e il HelloWorld producer example. Iniziare con le diagnosi riportate in bsl_memory.h e bsl_functional.h, quindi verificare che il progetto venga compilato senza la soppressione degli avvisi di deprecazione.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
cpp
Ambito
networking
Tipo di issue
Bug
Difficoltà
4/5
Tempo stimato
3-5 giorni
Stato di attività
Ferma
Chiarezza
Abbastanza chiara
Idoneità per principianti
35/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.