Skip to content

Avoid checking if a function uses itself as function pointer #207

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 14, 2017

Conversation

facchinm
Copy link
Member

@facchinm facchinm commented Jan 20, 2017

Fixes #206

The sample code from the issue provided a smart way to cheat the dumb FP parser.
In fact, the & is referred to the return type (correct) but the comparator doesn't know about semantics and simply prepends the ampersand before searching for the match.
So the code matches itself, which makes absolutely no sense.
Avoiding this occurrence fixes the issue, however the entire code for prototype line insertion should be refactored in a saner way (see #180 and #191 for another problem)

Fixes arduino#206

The sample code from the issue provided a smart way to cheat the dumb FP parser.
In fact, the & is referred to the return type (correct) but the comparator doesn't know about semantics and simply prepends the ampersand before searching for the match.
So the code matches itself, which makes absolutely no sense.
Avoiding this occurrence fixes the issue, however the entire code for prototype line insertion should be refactored in a saner way (see arduino#180 and arduino#191 for another problem)
@ArduinoBot
Copy link
Contributor

✅ Build completed.

⬇️ Build URL: http://downloads.arduino.cc/PR/arduino-builder/arduino-builder-207.zip

ℹ️ To test this build:

  1. Replace arduino-builder binary (you can find it where you installed the IDE) with the provided one

@facchinm facchinm merged commit 9165d1b into arduino:master Jun 14, 2017
@cmaglie cmaglie deleted the FunctionPointerAsArgumentFixed branch January 11, 2018 10:11
@cmaglie cmaglie added this to the 1.4.0 milestone Sep 10, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Build now failing when using template class.
4 participants