#82 Improve const correctness

aolserver_v40
open
Tom Jackson
None
5
2005-08-17
2005-08-07
Markus Elfring
No

Would you like to apply the advices from the article
"http://en.wikipedia.org/wiki/Const_correctness" to
your sources?
I suggest to add the key word "const" to the type
specifiers for parameters like the following examples.
http://aolserver.sourceforge.net/docs/devel/c/api/
-
http://cvs.sourceforge.net/viewcvs.py/aolserver/aolserver/include/ns.h?rev=1.78&view=markup
a (function "Ns_Match")
s1 (function "Ns_StrCaseFind")
pattern (function "Ns_StrNStr")
location (function "Ns_RelativeUrl")
url (functions "Ns_ParseUrl", "Ns_FetchURL")
url, base (function "Ns_AbsoluteUrl")
url, server (function "Ns_FetchPage")
handle, method, url (functions "Ns_UrlSpecific.et.+")
user (functions "Ns_GetU.+")
group (function "Ns_GetGid")

-
http://cvs.sourceforge.net/viewcvs.py/aolserver/aolserver/include/nsthread.h?rev=1.29&view=markup
name (function "Ns_ThreadSetName")
t1, t0 (function "Ns_DiffTime")
tlsPtr (function "Ns_TlsGet")

Discussion

  • Markus Elfring
    Markus Elfring
    2005-08-17

    • assigned_to: nobody --> rmadilo
     
  • Markus Elfring
    Markus Elfring
    2005-08-17

    Logged In: YES
    user_id=572001

    How do you think about the suggestions?