You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hawq.apache.org by pa...@apache.org on 2017/04/06 02:12:52 UTC
incubator-hawq git commit: HAWQ-1423. cmock framework does not
recognize __MAYBE_UNUSED.
Repository: incubator-hawq
Updated Branches:
refs/heads/master f5ffddf26 -> 8595cdb81
HAWQ-1423. cmock framework does not recognize __MAYBE_UNUSED.
Project: http://git-wip-us.apache.org/repos/asf/incubator-hawq/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-hawq/commit/8595cdb8
Tree: http://git-wip-us.apache.org/repos/asf/incubator-hawq/tree/8595cdb8
Diff: http://git-wip-us.apache.org/repos/asf/incubator-hawq/diff/8595cdb8
Branch: refs/heads/master
Commit: 8595cdb8154e4def242ac88b0c26067d69b7e0c5
Parents: f5ffddf
Author: Paul Guo <pa...@gmail.com>
Authored: Wed Apr 5 18:07:57 2017 +0800
Committer: Paul Guo <pa...@gmail.com>
Committed: Wed Apr 5 18:07:57 2017 +0800
----------------------------------------------------------------------
src/test/unit/mock/mocker.py | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-hawq/blob/8595cdb8/src/test/unit/mock/mocker.py
----------------------------------------------------------------------
diff --git a/src/test/unit/mock/mocker.py b/src/test/unit/mock/mocker.py
index b0285a7..49e4848 100755
--- a/src/test/unit/mock/mocker.py
+++ b/src/test/unit/mock/mocker.py
@@ -40,9 +40,9 @@ class CFile(object):
# function pattern
func_pat = re.compile(
# modifier
- r'(?:(static|inline|__inline__|__inline)\s+)*' +
+ r'(?:(static|inline|__inline__|__inline|__MAYBE_UNUSED)\s+)*' +
# rettype
- r'((?:const\s+)?(?:struct\s+|unsigned\s+)?\w+(?:[\s\*]+|\s+))(?:inline\s+|static\s+)?' +
+ r'((?:const\s+)?(?:struct\s+|unsigned\s+)?\w+(?:[\s\*]+|\s+))(?:inline\s+|static\s+|__MAYBE_UNUSED\s+)?' +
# funcname
r'(\w+)\s*'
# arguments
@@ -187,6 +187,7 @@ class FuncSignature(object):
def __init__(self, modifier, rettype, funcname, args):
self.modifier = modifier.strip()
self.rettype = re.sub('inline', '', rettype).strip()
+ self.rettype = re.sub('__MAYBE_UNUSED', '', rettype).strip()
self.funcname = funcname.strip()
self.args = self.parse_args(args)