Include What You Use

This commit is contained in:
Kent Ross 2021-09-15 17:38:09 -07:00
parent 6ec3ace497
commit 1ad817ef54
15 changed files with 65 additions and 10 deletions

View File

@ -3,8 +3,13 @@
#include <doctest/doctest.h>
#include "fast_float/fast_float.h"
#include <cmath>
#include <cstdio>
#include <iomanip>
#include <ios>
#include <limits>
#include <string>
#include <system_error>
#ifndef SUPPLEMENTAL_TEST_DATA_DIR
#define SUPPLEMENTAL_TEST_DATA_DIR "data/"

View File

@ -1,6 +1,8 @@
#include "fast_float/fast_float.h"
#include <iostream>
#include <string>
#include <system_error>
int main() {
const std::string input = "3,1416 xyz ";

View File

@ -1,6 +1,8 @@
#include "fast_float/fast_float.h"
#include <iostream>
#include <string>
#include <system_error>
int main() {
const std::string input = "3.1416 xyz ";

View File

@ -1,9 +1,13 @@
#include "fast_float/fast_float.h"
#include <iostream>
#include <cassert>
#include <cmath>
#include <cstdio>
#include <ios>
#include <iostream>
#include <limits>
#include <system_error>
template <typename T> char *to_string(T d, char *buffer) {
auto written = std::snprintf(buffer, 64, "%.*e",

View File

@ -1,9 +1,14 @@
#include "fast_float/fast_float.h"
#include <iostream>
#include <cassert>
#include <cmath>
#include <cstdio>
#include <ios>
#include <iostream>
#include <limits>
#include <string>
#include <system_error>
template <typename T> char *to_string(T d, char *buffer) {
auto written = std::snprintf(buffer, 64, "%.*e",

View File

@ -1,8 +1,12 @@
#include "fast_float/fast_float.h"
#include <iostream>
#include <cassert>
#include <cmath>
#include <cstdio>
#include <ios>
#include <iostream>
#include <limits>
#include <stdexcept>
#if defined(__CYGWIN__) || defined(__MINGW32__) || defined(__MINGW64__)
// Anything at all that is related to cygwin, msys and so forth will

View File

@ -1,9 +1,12 @@
#include "fast_float/fast_float.h"
#include <iostream>
#include <cassert>
#include <cmath>
#include <cstdio>
#include <ios>
#include <iostream>
#include <system_error>
template <typename T> char *to_string(T d, char *buffer) {
auto written = std::snprintf(buffer, 128, "%.*e",

View File

@ -1,8 +1,10 @@
#include "fast_float/fast_float.h"
#include <iostream>
#include <cassert>
#include <cmath>
#include <cstdio>
#include <ios>
#include <iostream>
template <typename T> char *to_string(T d, char *buffer) {
auto written = std::snprintf(buffer, 128, "%.*e",

View File

@ -1,8 +1,11 @@
#include "fast_float/fast_float.h"
#include <iostream>
#include <cassert>
#include <cmath>
#include <cstdio>
#include <ios>
#include <iostream>
#include <system_error>
template <typename T> char *to_string(T d, char *buffer) {
auto written = std::snprintf(buffer, 128, "%.*e",

View File

@ -1,6 +1,10 @@
#include "fast_float/fast_float.h"
#include <cctype>
#include <iostream>
#include <stdexcept>
#include <string>
#include <system_error>
#include <vector>
inline void Assert(bool Assertion) {

View File

@ -1,8 +1,12 @@
#include "fast_float/fast_float.h"
#include <ios>
#include <iostream>
#include <random>
#include <sstream>
#include <string>
#include <system_error>
#include <utility>
#include <vector>
@ -11,7 +15,6 @@
// always use this fallback because we cannot rely on it behaving as normal
// gcc.
#include <locale>
#include <sstream>
// workaround for CYGWIN
double cygwin_strtod_l(const char* start, char** end) {
double d;

View File

@ -1,8 +1,12 @@
#include "fast_float/fast_float.h"
#include <iostream>
#include <cassert>
#include <cmath>
#include <cstdio>
#include <ios>
#include <iostream>
#include <limits>
#include <system_error>
template <typename T> char *to_string(T d, char *buffer) {
auto written = std::snprintf(buffer, 64, "%.*e",

View File

@ -1,8 +1,11 @@
#include "fast_float/fast_float.h"
#include <iostream>
#include <cstdint>
#include <ios>
#include <iostream>
#include <random>
#include <system_error>
#include <utility>
#if defined(__CYGWIN__) || defined(__MINGW32__) || defined(__MINGW64__) || defined(sun) || defined(__sun)
// Anything at all that is related to cygwin, msys and so forth will

View File

@ -1,7 +1,11 @@
#include "fast_float/fast_float.h"
#include <iostream>
#include <cstdint>
#include <ios>
#include <iostream>
#include <random>
#include <system_error>
#include <utility>
#if defined(__CYGWIN__) || defined(__MINGW32__) || defined(__MINGW64__) || defined(sun) || defined(__sun)
// Anything at all that is related to cygwin, msys and so forth will

View File

@ -1,5 +1,12 @@
#include "fast_float/fast_float.h"
#include <cctype>
#include <cstdio>
#include <iostream>
#include <limits>
#include <stdexcept>
#include <string>
#include <system_error>
#include <vector>
#if defined(__CYGWIN__) || defined(__MINGW32__) || defined(__MINGW64__) || defined(sun) || defined(__sun)