|
OpenTTD Source
14.0-beta3
|
#include <stdint.h>#include <algorithm>#include <array>#include <bit>#include <cassert>#include <cctype>#include <cerrno>#include <climits>#include <cmath>#include <cstddef>#include <cstdint>#include <cstdio>#include <cstring>#include <cstdlib>#include <cwchar>#include <deque>#include <exception>#include <functional>#include <iterator>#include <list>#include <limits>#include <map>#include <memory>#include <numeric>#include <optional>#include <set>#include <span>#include <stdexcept>#include <string>#include <type_traits>#include <variant>#include <vector>Go to the source code of this file.
Macros | |
| #define | __STDC_LIMIT_MACROS |
| #define | NOACCESS(args) |
| #define | EMPTY_BASES |
| #define | PATHSEP "/" |
| #define | PATHSEPCHAR '/' |
| #define | PACK_N(type_dec, n) type_dec __attribute__((__packed__, aligned(n))) |
| #define | PACK(type_dec) PACK_N(type_dec, 1) |
| #define | debug_inline inline |
| #define | PERSONAL_DIR "" |
| #define | M_PI_2 1.57079632679489661923 |
| #define | M_PI 3.14159265358979323846 |
| #define | lengthof(x) (sizeof(x) / sizeof(x[0])) |
| Return the length of an fixed size array. More... | |
| #define | endof(x) (&x[lengthof(x)]) |
| Get the end element of an fixed size array. More... | |
| #define | lastof(x) (&x[lengthof(x) - 1]) |
| Get the last element of an fixed size array. More... | |
| #define | cpp_sizeof(base, variable) (sizeof(std::declval<base>().variable)) |
| Gets the size of a variable within a class. More... | |
| #define | cpp_lengthof(base, variable) (cpp_sizeof(base, variable) / cpp_sizeof(base, variable[0])) |
| Gets the length of an array variable within a class. More... | |
| #define | GNU_TARGET(x) |
| #define | FMT_HEADER_ONLY |
| #define | NOT_REACHED() NotReachedError(__LINE__, __FILE__) |
| #define | JSON_ASSERT(x) assert(x) |
| #define | MAX_PATH 260 |
| #define | MAX_UVALUE(type) ((type)~(type)0) |
| The largest value that can be entered in a variable. More... | |
| #define | IGNORE_UNINITIALIZED_WARNING_START |
| #define | IGNORE_UNINITIALIZED_WARNING_STOP |
Typedefs | |
| typedef uint8_t | byte |
| typedef unsigned int | uint |
Functions | |
| template<typename T > | |
| std::string | FS2OTTD (T name) |
| template<typename T > | |
| std::string | OTTD2FS (T name) |
| void | NotReachedError (int line, const char *file) |
| void | AssertFailedError (int line, const char *file, const char *expression) |
| void | free (const void *ptr) |
| Version of the standard free that accepts const pointers. More... | |
Definition of base types and functions in a cross-platform compatible way.
Definition in file stdafx.h.
| #define cpp_lengthof | ( | base, | |
| variable | |||
| ) | (cpp_sizeof(base, variable) / cpp_sizeof(base, variable[0])) |
| #define cpp_sizeof | ( | base, | |
| variable | |||
| ) | (sizeof(std::declval<base>().variable)) |
| #define endof | ( | x | ) | (&x[lengthof(x)]) |
| #define lastof | ( | x | ) | (&x[lengthof(x) - 1]) |
| #define lengthof | ( | x | ) | (sizeof(x) / sizeof(x[0])) |
| #define MAX_UVALUE | ( | type | ) | ((type)~(type)0) |
|
inline |
Version of the standard free that accepts const pointers.
| ptr | The data to free. |
Definition at line 379 of file stdafx.h.
Referenced by ScriptAllocator::CheckAllocation(), BinaryHeap::Clear(), Hash::Clear(), TrueTypeFontCache::ClearFontCache(), SpriteFontCache::ClearGlyphToSpriteMap(), ClearSnowLine(), DEFINE_POOL_METHOD(), Hash::Delete(), BinaryHeap::Free(), FreeEngine(), Path::GetCapacityRatio(), GetLayouter(), Gunzip(), HeightMapAdjustWaterLevel(), InitializeOldNames(), OpenGLBackend::InternalClearCursorCache(), IniLoadFile::LoadFromDisk(), TextfileWindow::LoadTextfile(), ZeroedMemoryAllocator::operator delete(), ZeroedMemoryAllocator::operator delete[](), ResetCustomAirports(), ResetOldNames(), StringFilter::SetFilterTerm(), VideoDriver_Dedicated::Stop(), CrashLogOSX::SurveyStacktrace(), Xunzip(), FixedSizeArray< SubArray, 1024 >::~FixedSizeArray(), FreeUnitIDGenerator::~FreeUnitIDGenerator(), ReusableBuffer< SpriteLoader::CommonPixel >::~ReusableBuffer(), and TrueTypeFontCache::~TrueTypeFontCache().