This is an automated email from the ASF dual-hosted git repository.
dkulp pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/avro.git
The following commit(s) were added to refs/heads/master by this push:
new 1e44880 Fix c++ windows build. IN and OUT are predefined macros.
1e44880 is described below
commit 1e44880328fb1e1c8f6e98d863c9d36938316904
Author: Leander Schulten <[email protected]>
AuthorDate: Tue Jun 1 01:26:09 2021 +0200
Fix c++ windows build. IN and OUT are predefined macros.
---
lang/c++/impl/avrogencpp.cc | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/lang/c++/impl/avrogencpp.cc b/lang/c++/impl/avrogencpp.cc
index 6157041..0b6b35a 100644
--- a/lang/c++/impl/avrogencpp.cc
+++ b/lang/c++/impl/avrogencpp.cc
@@ -804,8 +804,8 @@ static string readGuard(const string &filename) {
int main(int argc, char **argv) {
const string NS("namespace");
- const string OUT("output");
- const string IN("input");
+ const string OUT_FILE("output");
+ const string IN_FILE("input");
const string INCLUDE_PREFIX("include-prefix");
const string NO_UNION_TYPEDEF("no-union-typedef");
@@ -817,14 +817,14 @@ int main(int argc, char **argv) {
po::store(po::parse_command_line(argc, argv, desc), vm);
po::notify(vm);
- if (vm.count("help") || vm.count(IN) == 0 || vm.count(OUT) == 0) {
+ if (vm.count("help") || vm.count(IN_FILE) == 0 || vm.count(OUT_FILE) == 0)
{
std::cout << desc << std::endl;
return 1;
}
string ns = vm.count(NS) > 0 ? vm[NS].as<string>() : string();
- string outf = vm.count(OUT) > 0 ? vm[OUT].as<string>() : string();
- string inf = vm.count(IN) > 0 ? vm[IN].as<string>() : string();
+ string outf = vm.count(OUT_FILE) > 0 ? vm[OUT_FILE].as<string>() :
string();
+ string inf = vm.count(IN_FILE) > 0 ? vm[IN_FILE].as<string>() : string();
string incPrefix = vm[INCLUDE_PREFIX].as<string>();
bool noUnion = vm.count(NO_UNION_TYPEDEF) != 0;
if (incPrefix == "-") {