Skip to content

Commit

Permalink
[Release] annoying warning fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Agrael1 committed Oct 23, 2024
1 parent 6b2faab commit e785a1c
Show file tree
Hide file tree
Showing 28 changed files with 56 additions and 30 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

cmake_minimum_required(VERSION 3.22)

set(WISDOM_VERSION "0.3.8")
set(WISDOM_VERSION "0.3.9")
project("Wisdom" VERSION ${WISDOM_VERSION})

set(CMAKE_DEBUG_POSTFIX d)
Expand Down
4 changes: 4 additions & 0 deletions Changelog.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Version History

- 0.3.9

- Fixed annoying warning about class/struct mismatch in C++ API

- 0.3.8

- Fixed render pass for DX12 always clearing, despite of value
Expand Down
2 changes: 1 addition & 1 deletion bindings/wisdom.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

/** \mainpage Wisdom API Documentation
<b>Version 0.3.6</b>
<b>Version 0.3.9</b>
Copyright (c) 2024 Ilya Doroshenko. All rights reserved.
License: MIT
Expand Down
2 changes: 1 addition & 1 deletion generator/generator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2228,7 +2228,7 @@ std::string Generator::MakeCPPHandle(const WisHandle& s, std::string_view impl)
ReplaceAll(doc, "\n", "\n * ");
}

std::string head = wis::format("{}\nstruct {}{} : public wis::Impl{}{}", doc, impl, s.name, impl, s.name);
std::string head = wis::format("{}\class {}{} : public wis::Impl{}{}", doc, impl, s.name, impl, s.name);
std::string ctor = wis::format("public:\n using wis::Impl{}{}::Impl{}{};", impl, s.name, impl, s.name);

std::string funcs = "public:\n";
Expand Down
8 changes: 4 additions & 4 deletions wisdom/extensions/debug_info/wisdom/wisdom_debug.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ class ImplDX12DebugExtension : public QueryInternalExtension<DX12DebugExtension,
};

#pragma region DX12DebugExtension

struct DX12DebugExtension : public wis::ImplDX12DebugExtension {
class DX12DebugExtension : public wis::ImplDX12DebugExtension
{
public:
using wis::ImplDX12DebugExtension::ImplDX12DebugExtension;

Expand Down Expand Up @@ -116,8 +116,8 @@ class ImplVKDebugExtension : public QueryInternalExtension<VKDebugExtension, wis
};

#pragma region VKDebugExtension

struct VKDebugExtension : public wis::ImplVKDebugExtension {
class VKDebugExtension : public wis::ImplVKDebugExtension
{
public:
using wis::ImplVKDebugExtension::ImplVKDebugExtension;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/dx12/dx12_adapter.h
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,8 @@ class ImplDX12Adapter : public QueryInternal<DX12Adapter>
* @brief Represents physical device.
* Can safely be deleted once logical device has been created.
* */
struct DX12Adapter : public wis::ImplDX12Adapter {
class DX12Adapter : public wis::ImplDX12Adapter
{
public:
using wis::ImplDX12Adapter::ImplDX12Adapter;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/dx12/dx12_allocator.h
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,8 @@ class ImplDX12ResourceAllocator : public QueryInternal<DX12ResourceAllocator>
* @brief Main memory and resource allocator.
* Uses DXMA and VMA libraries which can allocate memory with O(1) complexity with TLSF algorithm.
* */
struct DX12ResourceAllocator : public wis::ImplDX12ResourceAllocator {
class DX12ResourceAllocator : public wis::ImplDX12ResourceAllocator
{
public:
using wis::ImplDX12ResourceAllocator::ImplDX12ResourceAllocator;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/dx12/dx12_command_list.h
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,8 @@ class ImplDX12CommandList : public QueryInternal<DX12CommandList>
/**
* @brief Represents command list for recording commands.
* */
struct DX12CommandList : public wis::ImplDX12CommandList {
class DX12CommandList : public wis::ImplDX12CommandList
{
public:
using wis::ImplDX12CommandList::ImplDX12CommandList;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/dx12/dx12_command_queue.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,8 @@ class ImplDX12CommandQueue : public QueryInternal<DX12CommandQueue>
/**
* @brief Represents command queue for executing command lists.
* */
struct DX12CommandQueue : public wis::ImplDX12CommandQueue {
class DX12CommandQueue : public wis::ImplDX12CommandQueue
{
public:
using wis::ImplDX12CommandQueue::ImplDX12CommandQueue;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/dx12/dx12_descriptor_buffer.h
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,8 @@ class ImplDX12DescriptorBuffer : public QueryInternal<DX12DescriptorBuffer>
/**
* @brief Represents descriptor buffer for binding descriptors.
* */
struct DX12DescriptorBuffer : public wis::ImplDX12DescriptorBuffer {
class DX12DescriptorBuffer : public wis::ImplDX12DescriptorBuffer
{
public:
using wis::ImplDX12DescriptorBuffer::ImplDX12DescriptorBuffer;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/dx12/dx12_device.h
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,8 @@ class ImplDX12Device : public QueryInternal<DX12Device>
* @brief Represents logical device.
* Creates all the resources and commands for rendering.
* */
struct DX12Device : public wis::ImplDX12Device {
class DX12Device : public wis::ImplDX12Device
{
public:
using wis::ImplDX12Device::ImplDX12Device;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/dx12/dx12_factory.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,8 @@ class ImplDX12Factory : public QueryInternal<DX12Factory>
* @brief Class for creating adapters.
* Can be safely destroyed after adapter has been chosen.
* */
struct DX12Factory : public wis::ImplDX12Factory {
class DX12Factory : public wis::ImplDX12Factory
{
public:
using wis::ImplDX12Factory::ImplDX12Factory;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/dx12/dx12_fence.h
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,8 @@ class ImplDX12Fence : public QueryInternal<DX12Fence>
/**
* @brief Represents fence for synchronization of GPU timeline.
* */
struct DX12Fence : public wis::ImplDX12Fence {
class DX12Fence : public wis::ImplDX12Fence
{
public:
using wis::ImplDX12Fence::ImplDX12Fence;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/dx12/dx12_memory.h
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,8 @@ class ImplDX12Memory : public QueryInternal<DX12Memory>
/**
* @brief Represents memory object for binding resources.
* */
struct DX12Memory : public wis::ImplDX12Memory {
class DX12Memory : public wis::ImplDX12Memory
{
public:
using wis::ImplDX12Memory::ImplDX12Memory;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/dx12/dx12_resource.h
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,8 @@ class DX12ShaderResource : public QueryInternal<DX12ShaderResource>
/**
* @brief Represents buffer object for storing linear data.
* */
struct DX12Buffer : public wis::ImplDX12Buffer {
class DX12Buffer : public wis::ImplDX12Buffer
{
public:
using wis::ImplDX12Buffer::ImplDX12Buffer;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/dx12/dx12_swapchain.h
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,8 @@ class ImplDX12SwapChain : public QueryInternal<DX12SwapChain>
/**
* @brief Represents swap chain object for presenting images.
* */
struct DX12SwapChain : public wis::ImplDX12SwapChain {
class DX12SwapChain : public wis::ImplDX12SwapChain
{
public:
using wis::ImplDX12SwapChain::ImplDX12SwapChain;

Expand Down
2 changes: 1 addition & 1 deletion wisdom/include/wisdom/generated/api/api.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

/** \mainpage Wisdom API Documentation
<b>Version 0.3.6</b>
<b>Version 0.3.9</b>
Copyright (c) 2024 Ilya Doroshenko. All rights reserved.
License: MIT
Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/vulkan/vk_adapter.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,8 @@ class ImplVKAdapter : public QueryInternal<VKAdapter>
* @brief Represents physical device.
* Can safely be deleted once logical device has been created.
* */
struct VKAdapter : public wis::ImplVKAdapter {
class VKAdapter : public wis::ImplVKAdapter
{
public:
using wis::ImplVKAdapter::ImplVKAdapter;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/vulkan/vk_allocator.h
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,8 @@ class ImplVKResourceAllocator : public QueryInternal<VKResourceAllocator>
* @brief Main memory and resource allocator.
* Uses DXMA and VMA libraries which can allocate memory with O(1) complexity with TLSF algorithm.
* */
struct VKResourceAllocator : public wis::ImplVKResourceAllocator {
class VKResourceAllocator : public wis::ImplVKResourceAllocator
{
public:
using wis::ImplVKResourceAllocator::ImplVKResourceAllocator;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/vulkan/vk_command_list.h
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,8 @@ class ImplVKCommandList : public QueryInternal<VKCommandList>
/**
* @brief Represents command list for recording commands.
* */
struct VKCommandList : public wis::ImplVKCommandList {
class VKCommandList : public wis::ImplVKCommandList
{
public:
using wis::ImplVKCommandList::ImplVKCommandList;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/vulkan/vk_command_queue.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,8 @@ class ImplVKCommandQueue : public QueryInternal<VKCommandQueue>
/**
* @brief Represents command queue for executing command lists.
* */
struct VKCommandQueue : public wis::ImplVKCommandQueue {
class VKCommandQueue : public wis::ImplVKCommandQueue
{
public:
using wis::ImplVKCommandQueue::ImplVKCommandQueue;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/vulkan/vk_descriptor_buffer.h
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,8 @@ class ImplVKDescriptorBuffer : public QueryInternal<VKDescriptorBuffer>
/**
* @brief Represents descriptor buffer for binding descriptors.
* */
struct VKDescriptorBuffer : public wis::ImplVKDescriptorBuffer {
class VKDescriptorBuffer : public wis::ImplVKDescriptorBuffer
{
public:
using wis::ImplVKDescriptorBuffer::ImplVKDescriptorBuffer;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/vulkan/vk_device.h
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,8 @@ class ImplVKDevice : public QueryInternal<VKDevice>
* @brief Represents logical device.
* Creates all the resources and commands for rendering.
* */
struct VKDevice : public wis::ImplVKDevice {
class VKDevice : public wis::ImplVKDevice
{
public:
using wis::ImplVKDevice::ImplVKDevice;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/vulkan/vk_factory.h
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,8 @@ class ImplVKFactory : public QueryInternal<VKFactory>
* @brief Class for creating adapters.
* Can be safely destroyed after adapter has been chosen.
* */
struct VKFactory : public wis::ImplVKFactory {
class VKFactory : public wis::ImplVKFactory
{
public:
using wis::ImplVKFactory::ImplVKFactory;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/vulkan/vk_fence.h
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,8 @@ class ImplVKFence : public QueryInternal<VKFence>
/**
* @brief Represents fence for synchronization of GPU timeline.
* */
struct VKFence : public wis::ImplVKFence {
class VKFence : public wis::ImplVKFence
{
public:
using wis::ImplVKFence::ImplVKFence;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/vulkan/vk_memory.h
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,8 @@ class ImplVKMemory : public QueryInternal<VKMemory>
/**
* @brief Represents memory object for binding resources.
* */
struct VKMemory : public wis::ImplVKMemory {
class VKMemory : public wis::ImplVKMemory
{
public:
using wis::ImplVKMemory::ImplVKMemory;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/vulkan/vk_resource.h
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,8 @@ class VKShaderResource : public QueryInternal<VKShaderResource>
/**
* @brief Represents buffer object for storing linear data.
* */
struct VKBuffer : public wis::ImplVKBuffer {
class VKBuffer : public wis::ImplVKBuffer
{
public:
using wis::ImplVKBuffer::ImplVKBuffer;

Expand Down
3 changes: 2 additions & 1 deletion wisdom/include/wisdom/vulkan/vk_swapchain.h
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,8 @@ class ImplVKSwapChain : public QueryInternal<VKSwapChain>
/**
* @brief Represents swap chain object for presenting images.
* */
struct VKSwapChain : public wis::ImplVKSwapChain {
class VKSwapChain : public wis::ImplVKSwapChain
{
public:
using wis::ImplVKSwapChain::ImplVKSwapChain;

Expand Down

0 comments on commit e785a1c

Please sign in to comment.