Add <cassert> header include
This fixes some Linux build failures.
This commit is contained in:
@@ -15,7 +15,7 @@ auto md5(MD5Digest& digest, std::string const& s) -> unsigned int
|
||||
|
||||
EVP_MD_CTX* md_context{EVP_MD_CTX_new()};
|
||||
assert(md_context != nullptr);
|
||||
EVP_DigestInit_ex2(md_context, md, nullptr);
|
||||
EVP_DigestInit_ex(md_context, md, nullptr);
|
||||
EVP_DigestUpdate(md_context, s.data(), s.length());
|
||||
EVP_DigestFinal_ex(md_context, digest.data(), &md_len);
|
||||
return md_len;
|
||||
@@ -40,4 +40,4 @@ auto main() -> int
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
@@ -15,7 +15,7 @@ auto md5(MD5Digest& digest, std::string const& s) -> unsigned int
|
||||
|
||||
EVP_MD_CTX* md_context{EVP_MD_CTX_new()};
|
||||
assert(md_context != nullptr);
|
||||
EVP_DigestInit_ex2(md_context, md, nullptr);
|
||||
EVP_DigestInit_ex(md_context, md, nullptr);
|
||||
EVP_DigestUpdate(md_context, s.data(), s.length());
|
||||
EVP_DigestFinal_ex(md_context, digest.data(), &md_len);
|
||||
return md_len;
|
||||
@@ -40,4 +40,4 @@ auto main() -> int
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
@@ -1,4 +1,5 @@
|
||||
#include <algorithm>
|
||||
#include <cassert>
|
||||
#include <cstdlib>
|
||||
#include <iostream>
|
||||
#include <limits>
|
||||
@@ -233,4 +234,4 @@ int main()
|
||||
|
||||
std::cout << "Best cost " << best_cost << "\n";
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
@@ -1,4 +1,5 @@
|
||||
#include <algorithm>
|
||||
#include <cassert>
|
||||
#include <cstdlib>
|
||||
#include <iostream>
|
||||
#include <limits>
|
||||
@@ -231,4 +232,4 @@ int main()
|
||||
|
||||
std::cout << "Best cost " << best_cost << "\n";
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
@@ -1,4 +1,5 @@
|
||||
#include <algorithm>
|
||||
#include <cassert>
|
||||
#include <cstdlib>
|
||||
#include <iostream>
|
||||
#include <limits>
|
||||
@@ -135,4 +136,4 @@ int main()
|
||||
state.execute(instructions[state.pc_]);
|
||||
}
|
||||
std::cout << "a = " << state.a_ << "\nb = " << state.b_ << '\n';
|
||||
}
|
||||
}
|
||||
|
@@ -1,4 +1,5 @@
|
||||
#include <algorithm>
|
||||
#include <cassert>
|
||||
#include <cstdlib>
|
||||
#include <iostream>
|
||||
#include <limits>
|
||||
@@ -135,4 +136,4 @@ int main()
|
||||
state.execute(instructions[state.pc_]);
|
||||
}
|
||||
std::cout << "a = " << state.a_ << "\nb = " << state.b_ << '\n';
|
||||
}
|
||||
}
|
||||
|
@@ -1,3 +1,4 @@
|
||||
#include <cassert>
|
||||
#include <cstdint>
|
||||
#include <iostream>
|
||||
#include <string>
|
||||
@@ -44,4 +45,4 @@ int main()
|
||||
std::cout << "Target row " << target_row << " column " << target_column << '\n';
|
||||
std::cout << "Row " << row << " column " << column << " num " << num << '\n';
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user