![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| High Level Programming Post questions about C, C++, Java, SQL, and other programming languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Optional non-const reference argument c++ ? | johnbach | High Level Programming | 2 | 09-17-2009 10:40 AM |
| cast from const void* to unsigned int loses precision | mannam srinivas | Red Hat | 0 | 08-08-2008 01:15 AM |
| int open(const char *pathname, int flags, mode_t mode) doubt... | csnmgeek | UNIX for Dummies Questions & Answers | 2 | 11-15-2007 01:41 PM |
| diff b/w char const in C/C++ | sarwan | High Level Programming | 3 | 10-11-2005 02:14 AM |
| Reference to a const | arun.viswanath | High Level Programming | 1 | 09-05-2005 06:20 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
Questions about const
Hi all,
I have some questions about functions. In a code I have (a .hpp file) there is this line which says: Code:
const Class_1_Name* Class_2_Name::MethodName(int ipart) const {return (ClassName*)_ref_to_method.At(ipart);}
Thank you in advance, ~eager |
|
||||
|
The second 'const' means that this member is not allowed to modify any values inside the class Class_2_name.
I am unable to divine the meaning of your second question. I do not recognize the _ref_to_method macro/operator/extension and don't understand what it's supposed to do... A reference to a method is pretty useless without a reference to its object in any case. |
|
||||
|
Thank you for the answer and apology for not replying back sooner.
by ref_2_method, I mean a reference to the method mentioned by MethodName. I will try to see if it is possible to show part of this code. Thank you so much again, ~eager |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|