MCPcopy Create free account
hub / github.com/catboost/catboost / DEF_CONV_NUM

Function DEF_CONV_NUM

util/stream/output.cpp:201–415  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

199 }
200
201DEF_CONV_NUM(bool, 64)
202
203DEF_CONV_CHR(char)
204DEF_CONV_CHR(signed char)
205DEF_CONV_CHR(unsigned char)
206
207DEF_CONV_NUM(signed short, 64)
208DEF_CONV_NUM(signed int, 64)
209DEF_CONV_NUM(signed long int, 64)
210DEF_CONV_NUM(signed long long int, 64)
211
212DEF_CONV_NUM(unsigned short, 64)
213DEF_CONV_NUM(unsigned int, 64)
214DEF_CONV_NUM(unsigned long int, 64)
215DEF_CONV_NUM(unsigned long long int, 64)
216
217DEF_CONV_NUM(float, 512)
218DEF_CONV_NUM(double, 512)
219DEF_CONV_NUM(long double, 512)
220
221#if !defined(_YNDX_LIBCXX_ENABLE_VECTOR_BOOL_COMPRESSION) || (_YNDX_LIBCXX_ENABLE_VECTOR_BOOL_COMPRESSION == 1)
222// TODO: acknowledge std::bitset::reference for both libc++ and libstdc++
223template <>
224void Out<typename std::vector<bool>::reference>(IOutputStream& o, const std::vector<bool>::reference& bit) {
225 return Out<bool>(o, static_cast<bool>(bit));
226}
227#endif
228
229#ifndef TSTRING_IS_STD_STRING
230template <>
231void Out<TBasicCharRef<TString>>(IOutputStream& o, const TBasicCharRef<TString>& c) {
232 o << static_cast<char>(c);
233}
234
235template <>
236void Out<TBasicCharRef<TUtf16String>>(IOutputStream& o, const TBasicCharRef<TUtf16String>& c) {
237 o << static_cast<wchar16>(c);
238}
239
240template <>
241void Out<TBasicCharRef<TUtf32String>>(IOutputStream& o, const TBasicCharRef<TUtf32String>& c) {
242 o << static_cast<wchar32>(c);
243}
244#endif
245
246template <>
247void Out<const void*>(IOutputStream& o, const void* t) {
248 o << Hex(size_t(t));
249}
250
251template <>
252void Out<void*>(IOutputStream& o, void* t) {
253 Out<const void*>(o, t);
254}
255
256using TNullPtr = decltype(nullptr);
257
258template <>

Callers

nothing calls this directly

Calls 4

TStdOutClass · 0.85
InstanceFunction · 0.85
HexFunction · 0.70
ifFunction · 0.50

Tested by

no test coverage detected