-
-
Notifications
You must be signed in to change notification settings - Fork 17
Check if the function is declared before declaring it. #36
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
Conversation
|
Sounds like you're inheriting class and function definitions with pthreads, then including the Composer autoloader again. If this is the case, that's the real problem to be fixed. If there is some other scenario that can lead to this problem, please describe it. |
|
Well, yes I need to include autoloader again. Without it I get undefined error. 🙃 |
|
I recommend using |
|
I'm using none currently, but lez see... |
|
@trowski Confirmed same issue. |
WyriHaximus
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This makes total sense to me but I rather see that we use a functions_include.php like we do in other packages, for example: https://github.com/reactphp/promise-stream/blob/master/src/functions_include.php
|
@WyriHaximus Thank you! I will make requested changes after I finish some critical work. |
|
@Niko9911 There's something else going wrong. We use pthreads in Here is our definition of |
|
@WyriHaximus Requested changes are made. |
WyriHaximus
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
One more thing, could you squash them into one commit?
|
Sure! |
|
Done, ty. |
|
Status? @clue |
|
Cheers, will tag this shortly 👍 |
|
THANK YOU EVERYBODY! |
|
Ok |






In case you use pthreads or something else related to threading you might encounter this issue. It happens only with functions and is fixable only by adding these checks. Another way to avoid this is to wrap functions as static into classes.