[Framework] Fix more warnings (clang, macos)#6083
Open
fredroy wants to merge 3 commits intosofa-framework:masterfrom
Open
[Framework] Fix more warnings (clang, macos)#6083fredroy wants to merge 3 commits intosofa-framework:masterfrom
fredroy wants to merge 3 commits intosofa-framework:masterfrom
Conversation
Contributor
Author
|
[ci-build][with-all-tests] |
hugtalbot
reviewed
Apr 24, 2026
Comment on lines
+855
to
+862
| if ( cell.val[0] != 0 ) voxels.push_back ( ( coord[0]+0 ) + ( coord[1]+0 ) *m_dataResolution[0] + ( coord[2]+0 ) *m_dataResolution[0]*m_dataResolution[1] ); //les voxels occupes ds ce cube | ||
| if ( cell.val[1] != 0 ) voxels.push_back ( ( coord[0]+1 ) + ( coord[1]+0 ) *m_dataResolution[0] + ( coord[2]+0 ) *m_dataResolution[0]*m_dataResolution[1] ); //les voxels occupes ds ce cube | ||
| if ( cell.val[3] != 0 ) voxels.push_back ( ( coord[0]+0 ) + ( coord[1]+1 ) *m_dataResolution[0] + ( coord[2]+0 ) *m_dataResolution[0]*m_dataResolution[1] ); //les voxels occupes ds ce cube | ||
| if ( cell.val[2] != 0 ) voxels.push_back ( ( coord[0]+1 ) + ( coord[1]+1 ) *m_dataResolution[0] + ( coord[2]+0 ) *m_dataResolution[0]*m_dataResolution[1] ); //les voxels occupes ds ce cube | ||
| if ( cell.val[4] != 0 ) voxels.push_back ( ( coord[0]+0 ) + ( coord[1]+0 ) *m_dataResolution[0] + ( coord[2]+1 ) *m_dataResolution[0]*m_dataResolution[1] ); //les voxels occupes ds ce cube | ||
| if ( cell.val[5] != 0 ) voxels.push_back ( ( coord[0]+1 ) + ( coord[1]+0 ) *m_dataResolution[0] + ( coord[2]+1 ) *m_dataResolution[0]*m_dataResolution[1] ); //les voxels occupes ds ce cube | ||
| if ( cell.val[7] != 0 ) voxels.push_back ( ( coord[0]+0 ) + ( coord[1]+1 ) *m_dataResolution[0] + ( coord[2]+1 ) *m_dataResolution[0]*m_dataResolution[1] ); //les voxels occupes ds ce cube | ||
| if ( cell.val[6] != 0 ) voxels.push_back ( ( coord[0]+1 ) + ( coord[1]+1 ) *m_dataResolution[0] + ( coord[2]+1 ) *m_dataResolution[0]*m_dataResolution[1] ); //les voxels occupes ds ce cube |
Contributor
There was a problem hiding this comment.
This clearly changes the check, is the check = 0 the one appropriate before the push_back ?
Contributor
There was a problem hiding this comment.
I don't see any problem here.
| kFSEventStreamCreateFlagFileEvents // FSEventStreamCreateFlags flags | ||
| ); | ||
| FSEventStreamScheduleWithRunLoop(m_eventStream,CFRunLoopGetCurrent(), kCFRunLoopDefaultMode); | ||
| FSEventStreamSetDispatchQueue(m_eventStream, dispatch_get_main_queue()); |
Contributor
There was a problem hiding this comment.
Doc says "Schedules the stream on the specified dispatch queue." where dispatch_get_main_queue() is the dispatch queue to use to receive events
The documentation also states that FSEventStreamSetDispatchQueue is now deprecated and the new function is advised to be used
So 👍
| real q0dqe = (real) ( qn.orientation[0]*dq.dual[0] + qn.orientation[1]*dq.dual[1] + qn.orientation[2]*dq.dual[2] + qn.orientation[3]*dq.dual[3]); | ||
|
|
||
| if(dq.orientation[0] || dq.orientation[1] || dq.orientation[2] || dq.orientation[3]) | ||
| if(dq.orientation[0] != 0 || dq.orientation[1] != 0 || dq.orientation[2] != 0 || dq.orientation[3] != 0) |
Contributor
There was a problem hiding this comment.
Don't we just want to check whether the quat exists?
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Mostly warning about implicit conversions (real to bool, signed/unsigned, to a smaller type)
The not-trivial one is Sofa/framework/Type/src/sofa/type/Mat.h
used with CRS templated on blocks (i.e Vec), it can lead conversion (copy) from Vec3f to Vec3d, thus triggering the deprecations set in #5675
NOTE: the AI was a local-deployed one (Qwen3.5)
[with-all-tests]
By submitting this pull request, I acknowledge that
I have read, understand, and agree SOFA Developer Certificate of Origin (DCO).
Reviewers will merge this pull-request only if