Fixes up a bunch of lib stuff

This commit is contained in:
2024-10-12 08:52:30 -04:00
parent 08eb20f19d
commit eccbd33af8
9 changed files with 16 additions and 14 deletions

View File

@@ -75,9 +75,9 @@
AppendFlag("-Wredundant-decls") #Warns about declarations that happen more then once.
AppendFlag("-Wctor-dtor-privacy") #Warns if a class appears unusable due to private ctor/dtors
AppendFlag("-Wdelete-non-virtual-dtor") #Warns about using `delete` on a class that has virtual functions without a virtual dtor
# Disabled because of older GCC compilers being unhappy with it
AppendFlag("-Winvalid-constexpr") #Warns that a function marked as constexpr can't possibly produce a constexpr expression
AppendFlag("-Wnoexcept") #Warns when a noexcept expression is false due to throwing
# Disabled due to spdlog
#AppendFlag("-Wnoexcept") #Warns when a noexcept expression is false due to throwing
AppendFlag("-Wnoexcept-type")
AppendFlag("-Wclass-memaccess") #Warns about accessing memory of a class. Which is likely invalid
AppendFlag("-Wregister") #Warns of use for `register` keyword. Which has been depreicated
@@ -104,7 +104,7 @@
AppendFlag("-fdiagnostics-show-template-tree") # Shows the template diagnostic info as a tree instead.
AppendFlag("-fdiagnostics-path-format=inline-events")
set(FGL_CONFIG "-std=c++23 -fmax-errors=6 -fconcepts-diagnostics-depth=8 -ftree-vectorize")
set(FGL_CONFIG "-std=c++23 -fmax-errors=3 -fconcepts-diagnostics-depth=8 -ftree-vectorize")
if (DEFINED USE_WERROR)
set(FGL_CONFIG "${FGL_CONFIG} -Werror")

View File

@@ -8,6 +8,7 @@
#pragma GCC diagnostic ignored "-Wold-style-cast"
#pragma GCC diagnostic ignored "-Weffc++"
#pragma GCC diagnostic ignored "-Wnon-virtual-dtor"
#pragma GCC diagnostic ignored "-Wnoexcept"
#include <spdlog/spdlog.h>
#pragma GCC diagnostic pop

View File

@@ -7,8 +7,8 @@
#include "BufferVector.hpp"
#include "concepts.hpp"
#include "engine/assets/transfer/TransferManager.hpp"
#include "engine/math/literals/size.hpp"
#include "engine/debug/logging/logging.hpp"
#include "engine/math/literals/size.hpp"
namespace fgl::engine
{
@@ -16,7 +16,7 @@ namespace fgl::engine
{
class Buffer;
}
}
} // namespace fgl::engine
namespace fgl::engine
{
@@ -25,10 +25,11 @@ namespace fgl::engine
{
public:
DeviceVector( memory::Buffer& buffer, const std::uint32_t count = 1 ) : BufferVector( buffer, count, sizeof( T ) )
DeviceVector( memory::Buffer& buffer, const std::uint32_t count = 1 ) :
BufferVector( buffer, count, sizeof( T ) )
{
log::debug(
"Creating DeviceVector of size {}", fgl::literals::size_literals::to_string( count * sizeof( T ) ) );
const auto size_str { fgl::literals::size_literals::to_string( count * sizeof( T ) ) };
log::debug( "Creating DeviceVector of size {}", size_str );
assert( count != 0 && "BufferSuballocationVector::BufferSuballocationVector() called with count == 0" );
}