Skip to content

Fixed compilation with old gcc #926

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 8, 2025
Merged

Fixed compilation with old gcc #926

merged 2 commits into from
Jun 8, 2025

Conversation

xeioex
Copy link
Contributor

@xeioex xeioex commented Jun 5, 2025

No description provided.

@xeioex xeioex mentioned this pull request Jun 5, 2025
3 tasks
@orgads
Copy link
Contributor

orgads commented Jun 6, 2025

It's still broken.

cc1: warnings being treated as errors
src\njs_value.c:541: warning: no previous prototype for 'njs_object_property_query'
cc1: warnings being treated as errors
src\njs_vmcode.h:419: warning: 'njs_function_new_object' declared inline after being called
src\njs_vmcode.h:419: warning: previous declaration of 'njs_function_new_object' was here

@xeioex
Copy link
Contributor Author

xeioex commented Jun 6, 2025

@orgads

I fixed the forgotten njs_function_new_object().

I do not understand why it complained about njs_object_property_query().
We have many such functions

grep njs_inline src/*.c
src/njs_array.c:njs_inline njs_int_t
src/njs_array.c:njs_inline njs_int_t
src/njs_builtin.c:njs_inline njs_int_t
src/njs_date.c:njs_inline int64_t
src/njs_date.c:njs_inline int64_t
src/njs_date.c:njs_inline uint64_t
src/njs_date.c:njs_inline double
src/njs_date.c:njs_inline int64_t
src/njs_date.c:njs_inline int64_t
src/njs_date.c:njs_inline double
src/njs_date.c:njs_inline int64_t
src/njs_date.c:njs_inline int64_t
src/njs_date.c:njs_inline double
src/njs_date.c:njs_inline int64_t
...

I also spend too many hours trying to build gcc-4.1, to try it myself.

@xeioex
Copy link
Contributor Author

xeioex commented Jun 6, 2025

@orgads

I hope it will compile this time.

This fixed compilation issues with gcc-4.1.
@xeioex xeioex requested a review from orgads June 6, 2025 21:28
@xeioex xeioex requested a review from VadimZhestikov June 8, 2025 00:28
Copy link
Contributor

@VadimZhestikov VadimZhestikov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good

@xeioex xeioex merged commit 1334534 into nginx:master Jun 8, 2025
1 check passed
@xeioex xeioex deleted the 32bit_long branch June 8, 2025 05:37
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.

3 participants