Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

Iterator related warnings in visual studio build

Abierto
#3,661 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
2/5
Tiempo estimado
1-2 días
Aptitud para principiantes
38/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Estancado
Stack tecnológico
cpp, wasm
Área
compilers

Línea de trabajo

Comienza con src/wasm-type.h, en las definiciones de iteradores mencionadas en las advertencias de Visual Studio, y luego reproduce la compilación para identificar las advertencias restantes relacionadas con los iteradores. Revisa las declaraciones de los iteradores afectados y verifica que la compilación de Visual Studio ya no informe de estas advertencias de obsolescencia de C++17.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

2>C:\src\binaryen\src\wasm-type.h(221,26): warning C4996: 'std::iterator<std::random_access_iterator_tag,wasm::Type,long,wasm::Type *,const wasm::Type &>': warning STL4015: The std::iterator class template (used as a base class to provide typedefs) is deprecated in C++17. (The <iterator> header is NOT deprecated.) The C++ Standard has never required user-defined iterators to derive from std::iterator. To fix this warning, stop deriving from std::iterator and start providing publicly accessible typedefs named iterator_category, value_type, difference_type, pointer, and reference. Note that value_type is required to be non-const, even for constant iterators. You can define _SILENCE_CXX17_ITERATOR_BASE_CLASS_DEPRECATION_WARNING or _SILENCE_ALL_CXX17_DEPRECATION_WARNINGS to acknowledge that you have received this warning. (compiling source file C:\src\binaryen\src\asmjs\asm_v_wasm.cpp)
2>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29333\include\xutility(6006,54): message : see declaration of 'std::iterator' (compiling source file C:\src\binaryen\src\asmjs\asm_v_wasm.cpp)
2>C:\src\binaryen\src\wasm-type.h(251,26): warning C4996: 'std::iterator<std::random_access_iterator_tag,wasm::Type,long,wasm::Type *,const wasm::Type &>::difference_type': warning STL4015: The std::iterator class template (used as a base class to provide typedefs) is deprecated in C++17. (The <iterator> header is NOT deprecated.) The C++ Standard has never required user-defined iterators to derive from std::iterator. To fix this warning, stop deriving from std::iterator and start providing publicly accessible typedefs named iterator_category, value_type, difference_type, pointer, and reference. Note that value_type is required to be non-const, even for constant iterators. You can define _SILENCE_CXX17_ITERATOR_BASE_CLASS_DEPRECATION_WARNING or _SILENCE_ALL_CXX17_DEPRECATION_WARNINGS to acknowledge that you have received this warning. (compiling source file C:\src\binaryen\src\asmjs\asm_v_wasm.cpp)
2>C:\src\binaryen\src\wasm-type.h(255,24): warning C4996: 'std::iterator<std::random_access_iterator_tag,wasm::Type,long,wasm::Type *,const wasm::Type &>::difference_type': warning STL4015: The std::iterator class template (used as a base class to provide typedefs) is deprecated in C++17. (The <iterator> header is NOT deprecated.) The C++ Standard has never required user-defined iterators to derive from std::iterator. To fix this warning, stop deriving from std::iterator and start providing publicly accessible typedefs named iterator_category, value_type, difference_type, pointer, and reference. Note that value_type is required to be non-const, even for constant iterators. You can define _SILENCE_CXX17_ITERATOR_BASE_CLASS_DEPRECATION_WARNING or _SILENCE_ALL_CXX17_DEPRECATION_WARNINGS to acknowledge that you have received this warning. (compiling source file C:\src\binaryen\src\asmjs\asm_v_wasm.cpp)
2>C:\src\binaryen\src\wasm-type.h(258,26): warning C4996: 'std::iterator<std::random_access_iterator_tag,wasm::Type,long,wasm::Type *,const wasm::Type &>::difference_type': warning STL4015: The std::iterator class template (used as a base class to provide typedefs) is deprecated in C++17. (The <iterator> header is NOT deprecated.) The C++ Standard has never required user-defined iterators to derive from std::iterator. To fix this warning, stop deriving from std::iterator and start providing publicly accessible typedefs named iterator_category, value_type, difference_type, pointer, and reference. Note that value_type is required to be non-const, even for constant iterators. You can define _SILENCE_CXX17_ITERATOR_BASE_CLASS_DEPRECATION_WARNING or _SILENCE_ALL_CXX17_DEPRECATION_WARNINGS to acknowledge that you have received this warning. (compiling source file C:\src\binaryen\src\asmjs\asm_v_wasm.cpp)
2>C:\src\binaryen\src\wasm-type.h(262,24): warning C4996: 'std::iterator<std::random_access_iterator_tag,wasm::Type,long,wasm::Type *,const wasm::Type &>::difference_type': warning STL4015: The std::iterator class template (used as a base class to provide typedefs) is deprecated in C++17. (The <iterator> header is NOT deprecated.) The C++ Standard has never required user-defined iterators to derive from std::iterator. To fix this warning, stop deriving from std::iterator and start providing publicly accessible typedefs named iterator_category, value_type, difference_type, pointer, and reference. Note that value_type is required to be non-const, even for constant iterators. You can define _SILENCE_CXX17_ITERATOR_BASE_CLASS_DEPRECATION_WARNING or _SILENCE_ALL_CXX17_DEPRECATION_WARNINGS to acknowledge that you have received this warning. (compiling source file C:\src\binaryen\src\asmjs\asm_v_wasm.cpp)
2>C:\src\binaryen\src\wasm-type.h(265,5): warning C4996: 'std::iterator<std::random_access_iterator_tag,wasm::Type,long,wasm::Type *,const wasm::Type &>::difference_type': warning STL4015: The std::iterator class template (used as a base class to provide typedefs) is deprecated in C++17. (The <iterator> header is NOT deprecated.) The C++ Standard has never required user-defined iterators to derive from std::iterator. To fix this warning, stop deriving from std::iterator and start providing publicly accessible typedefs named iterator_category, value_type, difference_type, pointer, and reference. Note that value_type is required to be non-const, even for constant iterators. You can define _SILENCE_CXX17_ITERATOR_BASE_CLASS_DEPRECATION_WARNING or _SILENCE_ALL_CXX17_DEPRECATION_WARNINGS to acknowledge that you have received this warning. (compiling source file C:\src\binaryen\src\asmjs\asm_v_wasm.cpp)
2>C:\src\binaryen\src\wasm-type.h(269,5): warning C4996: 'std::iterator<std::random_access_iterator_tag,wasm::Type,long,wasm::Type *,const wasm::Type &>::value_type': warning STL4015: The std::iterator class template (used as a base class to provide typedefs) is deprecated in C++17. (The <iterator> header is NOT deprecated.) The C++ Standard has never required user-defined iterators to derive from std::iterator. To fix this warning, stop deriving from std::iterator and start providing publicly accessible typedefs named iterator_category, value_type, difference_type, pointer, and reference. Note that value_type is required to be non-const, even for constant iterators. You can define _SILENCE_CXX17_ITERATOR_BASE_CLASS_DEPRECATION_WARNING or _SILENCE_ALL_CXX17_DEPRECATION_WARNINGS to acknowledge that you have received this warning. (compiling source file C:\src\binaryen\src\asmjs\asm_v_wasm.cpp)

And many more. Last modified here https://github.com/WebAssembly/binaryen/commit/9752196fd1357fbc129d1e4f53e8eb22cd6219f9 but it doesn't seem like the problem was introduced there.

Lenguaje dominante
WebAssembly
Estrellas
8.7k
Forks
893
Merge medio
1 d 11 h
PR fusionados (30 d)
74

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de WebAssembly/binaryen

Todos los issues de WebAssembly/binaryen

Issues similares

Más issues de Compilers

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.