Skip to content
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

macOS build fails with Xcode 15.2 #279

Open
gerd-moellmann opened this issue Feb 18, 2024 · 3 comments
Open

macOS build fails with Xcode 15.2 #279

gerd-moellmann opened this issue Feb 18, 2024 · 3 comments
Assignees
Labels
essential Will cause failure to meet customer requirements. Assign resources.

Comments

@gerd-moellmann
Copy link

Building using xcodebuild fails for me because the variable added in TransformAddOldNew() is unused (it really is), and -Werror,... is set. The following makes mps build successfully:

modified   code/trans.c
@@ -151,7 +151,6 @@ Res TransformAddOldNew(Transform transform,
 {
   Res res;
   Index i;
-  Count added = 0;
   Arena arena;
 
   AVERT(Transform, transform);
@@ -190,8 +189,6 @@ Res TransformAddOldNew(Transform transform,
     AVER(res != ResFAIL); /* It's a static error to add the same old twice. */
     if (res != ResOK)
       return res;
-    
-    ++added;
   }
 
   AVERT(Transform, transform);

@thejayps
Copy link
Contributor

Thanks for bringing this to our attention - it seems "added" is not used in the code but we'll double check that removing it is the correct fix

@gerd-moellmann
Copy link
Author

gerd-moellmann commented Mar 1, 2024 via email

@thejayps thejayps self-assigned this Jul 22, 2024
@thejayps thejayps added the essential Will cause failure to meet customer requirements. Assign resources. label Jul 22, 2024
@skangas
Copy link

skangas commented Jul 24, 2024

modified   code/trans.c
@@ -151,7 +151,6 @@ Res TransformAddOldNew(Transform transform,
 {
   Res res;
   Index i;
-  Count added = 0;
   Arena arena;
 
   AVERT(Transform, transform);
@@ -190,8 +189,6 @@ Res TransformAddOldNew(Transform transform,
     AVER(res != ResFAIL); /* It's a static error to add the same old twice. */
     if (res != ResOK)
       return res;
-    
-    ++added;
   }
 
   AVERT(Transform, transform);

For what it's worth, the above fix works here. Built on macOS 14.5 with Xcode 15.4.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
essential Will cause failure to meet customer requirements. Assign resources.
Projects
None yet
Development

No branches or pull requests

3 participants