Function taking a parameter with a struct tag on the last line before the opening { were wrongly treated as structs. Add some additional regex logic to try to catch those cases. Fixes #4136