I thought void* arithmetic was not allowed
I thought void* arithmetic was not allowed
- Subject: I thought void* arithmetic was not allowed
- From: Roland King <email@hidden>
- Date: Tue, 08 Apr 2014 20:38:23 +0800
I managed to end up with a piece of code which, distilled down, looks like this
void *ptr = base_ptr; void *other_ptr = ptr + 3;
when debugging through the code I used the _expression_ evaluator in lldb to evaluate "ptr+3" and I got an error message that arithmetic on void pointers is disallowed .. and I seem to remember it IS disallowed, in C at least.
But I get no warning on that line. Is there a warning flag I'm missing here? clang compiles it without warning or error, LLDB refuses to evaluate it, one of them is right, which? |
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden