Noisy MSVC warnings are disabled with laf-base flags now

This commit is contained in:
David Capello 2024-11-04 17:38:21 -03:00
parent c83dd16a43
commit 5a713448da
5 changed files with 3 additions and 30 deletions

2
laf

@ -1 +1 @@
Subproject commit 4618e1d256394f39e67fc0fe898dc77e8a1584fc
Subproject commit 5ec00f5373be19ecf77f9376584cdda5141f9890

View File

@ -19,12 +19,9 @@ if(MSVC)
if(LAF_BACKEND STREQUAL "skia")
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /LTCG")
endif()
add_definitions(-D_SCL_SECURE_NO_WARNINGS)
add_definitions(-wd4267) # disable warnings about signed/unsigned comparison
add_definitions(-wd4244) # disable warnings about possible loss of data
else()
# disable warnings about signed/unsigned comparison
# Disable warnings about signed/unsigned comparison.
# TODO we should remove this (or move it to laf-base)
add_definitions(-Wno-sign-compare)
endif()

View File

@ -33,11 +33,6 @@ namespace app {
using namespace ui;
using namespace app::skin;
// Disable warning about usage of "this" in initializer list.
#ifdef _MSC_VER
#pragma warning(disable:4355)
#endif
struct CanvasSizeParams : public NewParams {
Param<bool> ui { this, true, "ui" };
Param<int> left { this, 0, "left" };

View File

@ -78,10 +78,6 @@ namespace app {
using namespace ui;
#ifdef _MSC_VER
#pragma warning(disable:4355) // warning C4355: 'this' : used in base member initializer list
#endif
StandbyState::StandbyState()
: m_decorator(new Decorator(this))
, m_transformSelectionHandlesAreVisible(false)

View File

@ -11,21 +11,6 @@
#define ASEPRITE_CONFIG_H_INCLUDED
// In MSVC
#ifdef _MSC_VER
// Avoid warnings about insecure standard C++ functions
#ifndef _CRT_SECURE_NO_WARNINGS
#define _CRT_SECURE_NO_WARNINGS
#endif
// Disable warning C4355 in MSVC: 'this' used in base member initializer list
#pragma warning(disable:4355)
// Disable warning C4710 in MSVC: function not inlined (generated by MSVC header files)
// https://docs.microsoft.com/en-us/cpp/error-messages/compiler-warnings/compiler-warning-level-4-c4710
#pragma warning(disable:4710)
#endif
#include "base/base.h"
#include "base/debug.h"
#include "base/log.h"