Skip to content

Commit

Permalink
Replace EOF with char_traits (#4532)
Browse files Browse the repository at this point in the history
* 📝 update customers

* ♻️ replace EOF with char_traits #2755
  • Loading branch information
nlohmann authored Dec 10, 2024
1 parent 589641b commit 20ae363
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 9 deletions.
4 changes: 3 additions & 1 deletion docs/mkdocs/docs/home/customers.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
The library is used in multiple projects, applications, operating systems, etc. The list below is not exhaustive, but
the result of an internet search. If you know further customers of the library, [please let me know](mailto:mail@nlohmann.me).

![](../images/customers.png)
[![](../images/customers.png)](../images/customers.png)

## Space Exploration

Expand Down Expand Up @@ -70,6 +70,7 @@ the result of an internet search. If you know further customers of the library,
- [**ImHex**](https://github.com/WerWolv/ImHex), a hex editor designed for reverse engineering, providing advanced features for data analysis and manipulation
- [**Intel GPA Framework**](https://intel.github.io/gpasdk-doc/src/licenses.html), a suite of cross-platform tools for capturing, analyzing, and optimizing graphics applications across different APIs
- [**Meta Yoga**](https://github.com/facebook/yoga), a layout engine that facilitates flexible and efficient user interface design across multiple platforms
- [**MKVToolNix**](https://mkvtoolnix.download/doc/README.md), a set of tools for creating, editing, and inspecting MKV (Matroska) multimedia container files
- [**NVIDIA Nsight Compute**](https://docs.nvidia.com/nsight-compute/2022.2/pdf/CopyrightAndLicenses.pdf), a performance analysis tool for CUDA applications that provides detailed insights into GPU performance metrics
- [**Notepad++**](https://github.com/notepad-plus-plus/notepad-plus-plus), a free source code editor that supports various programming languages
- [**OpenRGB**](https://gitlab.com/CalcProgrammer1/OpenRGB), an open source RGB lighting control that doesn't depend on manufacturer software
Expand Down Expand Up @@ -129,6 +130,7 @@ the result of an internet search. If you know further customers of the library,

- [**Arcturus HoloSuite**](https://www.datocms-assets.com/104353/1698904597-holosuite-third-party-software-credits-and-attributions-2.pdf), a software toolset for capturing, editing, and streaming volumetric video, featuring advanced compression technologies for high-quality 3D content creation
- [**azul**](https://pure.tudelft.nl/ws/files/85338589/tgis.12673.pdf), a fast and efficient 3D city model viewer designed for visualizing urban environments and spatial data
- [**Blender**](https://projects.blender.org/blender/blender/search?q=nlohmann), a free and open-source 3D creation suite for modeling, animation, rendering, and more
- [**cpplot**](https://cpplot.readthedocs.io/en/latest/library_api/function_eigen_8h_1ac080eac0541014c5892a55e41bf785e6.html), a library for creating interactive graphs and charts in C++, which can be viewed in web browsers
- [**NVIDIA Omniverse**](https://docs.omniverse.nvidia.com/composer/latest/common/product-licenses/usd-explorer/usd-explorer-2023.2.0-licenses-manifest.html), a platform for 3D content creation and collaboration that enables real-time simulations and interactive experiences across various industries
- [**Pixar Renderman**](https://rmanwiki-26.pixar.com/space/REN26/19662083/Legal+Notice), a photorealistic 3D rendering software developed by Pixar, widely used in the film industry for creating high-quality visual effects and animations
Expand Down
Binary file modified docs/mkdocs/docs/images/customers.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 4 additions & 4 deletions include/nlohmann/detail/meta/type_traits.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@
#pragma once

#include <limits> // numeric_limits
#include <string> // char_traits
#include <tuple> // tuple
#include <type_traits> // false_type, is_constructible, is_integral, is_same, true_type
#include <utility> // declval
#include <tuple> // tuple
#include <string> // char_traits

#include <nlohmann/detail/iterators/iterator_traits.hpp>
#include <nlohmann/detail/macro_scope.hpp>
Expand Down Expand Up @@ -211,7 +211,7 @@ struct char_traits<unsigned char> : std::char_traits<char>

static constexpr int_type eof() noexcept
{
return static_cast<int_type>(EOF);
return static_cast<int_type>(std::char_traits<char>::eof());
}
};

Expand All @@ -235,7 +235,7 @@ struct char_traits<signed char> : std::char_traits<char>

static constexpr int_type eof() noexcept
{
return static_cast<int_type>(EOF);
return static_cast<int_type>(std::char_traits<char>::eof());
}
};

Expand Down
8 changes: 4 additions & 4 deletions single_include/nlohmann/json.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -3273,10 +3273,10 @@ NLOHMANN_JSON_NAMESPACE_END


#include <limits> // numeric_limits
#include <string> // char_traits
#include <tuple> // tuple
#include <type_traits> // false_type, is_constructible, is_integral, is_same, true_type
#include <utility> // declval
#include <tuple> // tuple
#include <string> // char_traits

// #include <nlohmann/detail/iterators/iterator_traits.hpp>
// __ _____ _____ _____
Expand Down Expand Up @@ -3658,7 +3658,7 @@ struct char_traits<unsigned char> : std::char_traits<char>

static constexpr int_type eof() noexcept
{
return static_cast<int_type>(EOF);
return static_cast<int_type>(std::char_traits<char>::eof());
}
};

Expand All @@ -3682,7 +3682,7 @@ struct char_traits<signed char> : std::char_traits<char>

static constexpr int_type eof() noexcept
{
return static_cast<int_type>(EOF);
return static_cast<int_type>(std::char_traits<char>::eof());
}
};

Expand Down

0 comments on commit 20ae363

Please sign in to comment.