mirror of
https://github.com/Z3Prover/z3
synced 2025-04-23 17:15:31 +00:00
Tabs
This commit is contained in:
parent
a258236229
commit
a7d5bb7b36
14 changed files with 63 additions and 63 deletions
|
@ -29,7 +29,7 @@ Revision History:
|
|||
#include<fenv.h>
|
||||
#endif
|
||||
|
||||
#if defined(__x86_64__) || defined(_M_X64) || \
|
||||
#if defined(__x86_64__) || defined(_M_X64) || \
|
||||
defined(__i386) || defined(_M_IX86)
|
||||
#define USE_INTRINSICS
|
||||
#endif
|
||||
|
|
|
@ -52,7 +52,7 @@ void disable_trace(const char * tag) {
|
|||
|
||||
bool is_trace_enabled(const char * tag) {
|
||||
return g_enable_all_trace_tags ||
|
||||
(g_enabled_trace_tags && get_enabled_trace_tags().contains(const_cast<char *>(tag)));
|
||||
(g_enabled_trace_tags && get_enabled_trace_tags().contains(const_cast<char *>(tag)));
|
||||
}
|
||||
|
||||
void close_trace() {
|
||||
|
|
|
@ -115,22 +115,22 @@ void format2ostream(std::ostream & out, char const* msg, va_list args) {
|
|||
while (true) {
|
||||
int nc = VPRF(buff.c_ptr(), buff.size(), msg, args);
|
||||
#if !defined(_WINDOWS) && defined(_AMD64_)
|
||||
// For some strange reason, on Linux 64-bit version, va_list args is reset by vsnprintf.
|
||||
// Z3 crashes when trying to use va_list args again.
|
||||
// For some strange reason, on Linux 64-bit version, va_list args is reset by vsnprintf.
|
||||
// Z3 crashes when trying to use va_list args again.
|
||||
// Hack: I truncate the message instead of expanding the buffer to make sure that
|
||||
// va_list args is only used once.
|
||||
END_ERR_HANDLER();
|
||||
if (nc < 0) {
|
||||
// vsnprintf didn't work, so we just print the msg
|
||||
out << msg;
|
||||
return;
|
||||
}
|
||||
if (nc >= static_cast<int>(buff.size())) {
|
||||
END_ERR_HANDLER();
|
||||
if (nc < 0) {
|
||||
// vsnprintf didn't work, so we just print the msg
|
||||
out << msg;
|
||||
return;
|
||||
}
|
||||
if (nc >= static_cast<int>(buff.size())) {
|
||||
// truncate the message
|
||||
buff[buff.size() - 1] = 0;
|
||||
}
|
||||
}
|
||||
out << buff.c_ptr();
|
||||
return;
|
||||
return;
|
||||
#else
|
||||
if (nc >= 0 && nc < static_cast<int>(buff.size()))
|
||||
break; // success
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue