calculating the size of an array passed to a function 
Author Message
 calculating the size of an array passed to a function

Hi,
  when I pass a 1D array to a function as a pointer sizeof() will give me
the size of the pointer. Is there anyway I can calculate the size of the
recieved array without having to pass a length parameter as well?

TIA,

--
-------------------------------------------------------------------

417 Davey Laboratory           | web  : www.jijo.cjb.net
Department of Chemistry        |        www.rajarshi.outputto.com
Pennsylvania State University  | ICQ  : 123242928
                               | AIM  : LoverOfPanda
-------------------------------------------------------------------
GPG Fingerprint: DCCB 4D1A 5A8B 2F5A B5F6  1F9E CDC4 5574 9017 AF2A
Public Key     : http://www.*-*-*.com/
-------------------------------------------------------------------
All seems condemned in the long run to approximate a state akin to
Gaussian noise.
                -- James Martin



Tue, 22 Jun 2004 00:29:37 GMT  
 calculating the size of an array passed to a function
Sorry - wrong group :(

--
-------------------------------------------------------------------

417 Davey Laboratory           | web  : www.jijo.cjb.net
Department of Chemistry        |        www.rajarshi.outputto.com
Pennsylvania State University  | ICQ  : 123242928
                               | AIM  : LoverOfPanda
-------------------------------------------------------------------
GPG Fingerprint: DCCB 4D1A 5A8B 2F5A B5F6  1F9E CDC4 5574 9017 AF2A
Public Key     : http://pgp.mit.edu/
-------------------------------------------------------------------
Q:  What's polite and works for the phone company?
A:  A deferential operator.



Tue, 22 Jun 2004 00:31:29 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Passing array valued functions as argument to function.

2. ADIR() Size vs Calculated Size

3. Newbie question: passing unknown size array

4. Passing fixed size arrays in common blocks.

5. Max Array Sizes Passed to procs

6. Passing array as argument to function

7. Passing Arrays To Functions

8. Pass array to function?

9. passing arrays to c functions

10. How do you pass an array of characters using the DLL functions

11. passing array to function

12. Q: Passing stem array to external function?

 

 
Powered by phpBB® Forum Software