You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Incompatible function pointer types:
The errors occurred when passing function pointers as arguments to the rb_ensure function.
The rb_ensure function expects the first argument to be a function pointer that takes a single VALUE parameter and returns a VALUE.
However, the function pointers being passed (get_text_elements_internal, get_categories_internal) had different parameter types (get_text_elements_param*, get_categories_param*) instead of VALUE.
To fix this, you need to modify the function definitions to take a VALUE parameter and convert it to the appropriate pointer type inside the function.
Operand type mismatch:
The errors occurred when attempting to convert a variable of type WString directly to VALUE.
The WString type is a struct, not a pointer or arithmetic type, so it cannot be directly converted to VALUE.
To fix this, you need to pass the address of the WString variable as a pointer and then convert that pointer to VALUE using a cast.
Incompatible function pointer types in the ensure callback:
The errors occurred when passing function pointers as the ensure callback to the rb_ensure function.
The rb_ensure function expects the ensure callback to be a function pointer that takes a single VALUE parameter and returns a VALUE.
However, the ensure callback functions (get_text_elements_ensure, get_categories_ensure) had a different parameter type (WString*) instead of VALUE.
To fix this, you need to modify the ensure callback functions to take a VALUE parameter and convert it back to a WString* pointer inside the function.
Overall, the main issues were related to incompatible function pointer types and incorrect type conversions when passing arguments to the rb_ensure function. The fixes involve modifying the function definitions and ensure callbacks to take VALUE parameters and perform the necessary type conversions inside the functions.
Thank you for taking the time to provide these fixes, but I'm not sure how to proceed here. This repository has always served as a mirror only (see the contributing guidelines). Now I notice that the original author seems to have disappeared from the internet. However, I don't see myself taking up maintaining the library; I just don't have the need for it anymore.
So, I'm sorry to say, someone else has to step up if you want to continue using this library (at least on macOS).
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Arquitecture: MacOS Sonoma 14.4
Ruby: ruby 3.2.0 (2022-12-25 revision a528908271) [arm64-darwin23]
Incompatible function pointer types:
The errors occurred when passing function pointers as arguments to the rb_ensure function.
The rb_ensure function expects the first argument to be a function pointer that takes a single VALUE parameter and returns a VALUE.
However, the function pointers being passed (get_text_elements_internal, get_categories_internal) had different parameter types (get_text_elements_param*, get_categories_param*) instead of VALUE.
To fix this, you need to modify the function definitions to take a VALUE parameter and convert it to the appropriate pointer type inside the function.
Operand type mismatch:
The errors occurred when attempting to convert a variable of type WString directly to VALUE.
The WString type is a struct, not a pointer or arithmetic type, so it cannot be directly converted to VALUE.
To fix this, you need to pass the address of the WString variable as a pointer and then convert that pointer to VALUE using a cast.
Incompatible function pointer types in the ensure callback:
The errors occurred when passing function pointers as the ensure callback to the rb_ensure function.
The rb_ensure function expects the ensure callback to be a function pointer that takes a single VALUE parameter and returns a VALUE.
However, the ensure callback functions (get_text_elements_ensure, get_categories_ensure) had a different parameter type (WString*) instead of VALUE.
To fix this, you need to modify the ensure callback functions to take a VALUE parameter and convert it back to a WString* pointer inside the function.
Overall, the main issues were related to incompatible function pointer types and incorrect type conversions when passing arguments to the rb_ensure function. The fixes involve modifying the function definitions and ensure callbacks to take VALUE parameters and perform the necessary type conversions inside the functions.