Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Standard library header <codecvt> is removed in C++17 #303

Open
wants to merge 102 commits into
base: dev
Choose a base branch
from

Conversation

shleym2000
Copy link
Contributor

This change would allow OpenNN to continue evolving into higher C++ standards.

Here it gets replaced with Windows equivalent. Code for replacement function is found on https://stackoverflow.com/questions/42946335/deprecated-header-codecvt-replacement

@shleym2000
Copy link
Contributor Author

This PR also closes #292 issue.

@@ -1039,7 +1039,7 @@ Tensor<type, 1> LossIndex::calculate_numerical_gradient()

for(Index i = 0; i < parameters_number; i++)
{
h = 0.01; // calculate_h(parameters(i));
h = static_cast<type>(0.01); // calculate_h(parameters(i));
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Prevents from warning about conversion from double to opennn::type

@@ -9,7 +9,9 @@

#define EIGEN_PERMANENTLY_DISABLE_STUPID_WARNINGS

#define _CRT_SECURE_NO_WARNINGS
#ifndef _CRT_SECURE_NO_WARNINGS
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Prevents from warnings about duplicate _CRT_SECURE_NO_WARNINGS definitions for almost every file being compiled

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant