From 125fcdef3c0ef99d083bd36054890ee0d8c47a31 Mon Sep 17 00:00:00 2001 From: Mark VanderVoord Date: Tue, 30 Jun 2026 11:28:22 -0400 Subject: [PATCH] Fix format of latest regex. --- lib/cmock_header_parser.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/cmock_header_parser.rb b/lib/cmock_header_parser.rb index 7c00fb1..c314003 100644 --- a/lib/cmock_header_parser.rb +++ b/lib/cmock_header_parser.rb @@ -330,7 +330,7 @@ class CMockHeaderParser source.gsub!(/(^|\W+)(?:#{@c_strippables.join('|')})(?=$|\W+)/, '\1') unless @c_strippables.empty? # remove known attributes slated to be stripped # scan standalone function pointers and remove them, because they can just be ignored - source.gsub!(/[\w][\w\s*]*\(\s*\*\s*\w+\s*\)\s*\([^)]*\)\s*;/, ';') + source.gsub!(/\w[\w\s*]*\(\s*\*\s*\w+\s*\)\s*\([^)]*\)\s*;/, ';') # scan for functions which return function pointers, because they are a pain source.gsub!(/([\w\s*]+)\(*\(\s*\*([\w\s*]+)\s*\(([\w\s*,]*)\)\)\s*\(([\w\s*,]*)\)\)*/) do |_m|