Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/CSFML/Char32.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ static_assert(alignof(sfChar32) == alignof(char32_t));
////////////////////////////////////////////////////////////
// Define utils to copy from / to sfChar32 and sf::String
////////////////////////////////////////////////////////////
inline sfChar32* copyToChar32(const sf::String& str)
[[nodiscard]] inline sfChar32* copyToChar32(const sf::String& str)
{
std::size_t byteCount = sizeof(sfChar32) * str.getSize();
auto* utf32 = static_cast<sfChar32*>(malloc(byteCount + sizeof(sfChar32)));
Expand Down
4 changes: 2 additions & 2 deletions src/CSFML/Network/IpAddress.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
namespace
{
// Helper function for converting a SFML address to a CSFML one
sfIpAddress fromSFMLAddress(std::optional<sf::IpAddress> address)
[[nodiscard]] sfIpAddress fromSFMLAddress(std::optional<sf::IpAddress> address)
{
sfIpAddress result = {0};

Expand All @@ -48,7 +48,7 @@ sfIpAddress fromSFMLAddress(std::optional<sf::IpAddress> address)
}

// Helper function for converting a CSFML address to a SFML one
std::optional<sf::IpAddress> toSFMLAddress(sfIpAddress address)
[[nodiscard]] std::optional<sf::IpAddress> toSFMLAddress(sfIpAddress address)
{
return sf::IpAddress::resolve(address.address);
}
Expand Down