|
Page 1 of 1
|
[ 3 posts ] |
|
element access for arrays not working with paranthesis
Author |
Message |
felix-freiberger
Rookie
Joined: Sat Dec 04, 2010 10:32 am Posts: 13
|
 element access for arrays not working with paranthesis
Hi, in RobotC 3.6, this code compiles: while this doesn't: Is that a bug? How can I dereference a pointer to an array and look up an element of the array? (*testPointer)[2] won't work. --Felix
|
Sun May 12, 2013 1:35 pm |
|
 |
mightor
Site Admin
Joined: Wed Mar 05, 2008 8:14 am Posts: 3654 Location: Rotterdam, The Netherlands
|
 Re: element access for arrays not working with paranthesis
What exactly are you trying to achieve? The following code does exactly what it is supposed to do: What are you looking to dereference and why? This also works quite nicely:
_________________| Professional Conduit of Reasonableness| (Title bestowed upon on the 8th day of November, 2013) | My Blog: I'd Rather Be Building Robots| ROBOTC 3rd Party Driver Suite: [ Project Page]
|
Sun May 12, 2013 4:17 pm |
|
 |
felix-freiberger
Rookie
Joined: Sat Dec 04, 2010 10:32 am Posts: 13
|
 Re: element access for arrays not working with paranthesis
Hi, that seems to work for me, thanks! I was trying to do something like that: --Felix
|
Mon May 13, 2013 5:25 am |
|
|
|
Page 1 of 1
|
[ 3 posts ] |
|
Who is online |
Users browsing this forum: No registered users and 2 guests |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot post attachments in this forum
|
|