Logical Combination: bypass combination flag in hs_expression_info.

Fixes github issue #291
This commit is contained in:
Chang, Harry
2021-03-10 07:20:01 +00:00
committed by Konstantinos Margaritis
parent 2e60bdde8a
commit 5307bbd1dc
3 changed files with 14 additions and 12 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright (c) 2015-2020, Intel Corporation
* Copyright (c) 2015-2021, Intel Corporation
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
@@ -517,6 +517,12 @@ hs_error_t hs_expression_info_int(const char *expression, unsigned int flags,
return HS_COMPILER_ERROR;
}
if (flags & HS_FLAG_COMBINATION) {
*error = generateCompileError("Invalid parameter: unsupported "
"logical combination expression", -1);
return HS_COMPILER_ERROR;
}
*info = nullptr;
*error = nullptr;