Skip to content

Commit b475823

Browse files
committed
Change JSON output logic to encode uint64 value as strings
1 parent e36e5d1 commit b475823

File tree

2 files changed

+2
-6
lines changed

2 files changed

+2
-6
lines changed

Src/ReportFormatter/JSONReportFormatter.cpp

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -133,11 +133,7 @@ void JSONReportFormatter::AddFieldUint32(std::wstring_view name, uint32_t value,
133133

134134
void JSONReportFormatter::AddFieldUint64(std::wstring_view name, uint64_t value, std::wstring_view unit /* = {}*/)
135135
{
136-
assert(!name.empty());
137-
PushNewElement();
138-
139-
std::wstring escapedName = EscapeString(name);
140-
Printer::PrintFormat(m_PrettyPrint ? L"\"{}\": {}" : L"\"{}\":{}", std::make_wformat_args(escapedName, value));
136+
AddFieldString(name, std::to_wstring(value));
141137
}
142138

143139
void JSONReportFormatter::AddFieldSize(std::wstring_view name, uint64_t value)

Src/Utils.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ For more information, see files README.md, LICENSE.txt.
1111

1212
const wchar_t* const PROGRAM_NAME = L"D3d12info";
1313
const char* const PROGRAM_NAME_ANSI = "D3d12info";
14-
const wchar_t* const PROGRAM_VERSION = L"3.12.2";
14+
const wchar_t* const PROGRAM_VERSION = L"3.13.0";
1515
const uint32_t PROGRAM_VERSION_NUMBER = (3u << 20) | (12u << 10) | (2u);
1616

1717
wstring SizeToStr(uint64_t size)

0 commit comments

Comments
 (0)