[m-dev.] diff: namespace cleanup of string.m
Peter Ross
peter.ross at miscrit.be
Tue Aug 8 19:33:20 AEST 2000
And some more I missed.
===================================================================
Estimated hours taken: 0.2
string.m:
Add some MR_ prefixes.
Index: string.m
===================================================================
RCS file: /home/mercury1/repository/mercury/library/string.m,v
retrieving revision 1.123
diff -u -r1.123 string.m
--- string.m 2000/08/08 09:13:44 1.123
+++ string.m 2000/08/08 09:29:15
@@ -1614,7 +1614,7 @@
:- pragma c_code(string__to_int_list(Str::in, IntList::out),
[will_not_call_mercury, thread_safe], "{
- const char *p = Str + strlen(Str);
+ MR_ConstString p = Str + strlen(Str);
IntList = MR_list_empty_msg(MR_PROC_LABEL);
while (p > Str) {
p--;
@@ -1645,7 +1645,7 @@
*/
incr_hp_atomic_msg(str_ptr, size / sizeof(MR_Word),
MR_PROC_LABEL, ""string:string/0"");
- Str = (char *) str_ptr;
+ Str = (MR_String) str_ptr;
/*
** loop to copy the characters from the int_list to the string
*/
@@ -1767,7 +1767,7 @@
incr_hp_atomic_msg(tmp,
(len_1 + len_2 + sizeof(MR_Word)) / sizeof(MR_Word),
MR_PROC_LABEL, ""string:string/0"");
- S3 = (char *) tmp;
+ S3 = (MR_String) tmp;
strcpy(S3, S1);
strcpy(S3 + len_1, S2);
}").
@@ -1886,7 +1886,7 @@
incr_hp_atomic_msg(tmp,
(Count + sizeof(MR_Word)) / sizeof(MR_Word),
MR_PROC_LABEL, ""string:string/0"");
- Left = (char *) tmp;
+ Left = (MR_String) tmp;
memcpy(Left, Str, Count);
Left[Count] = '\\0';
/*
--------------------------------------------------------------------------
mercury-developers mailing list
Post messages to: mercury-developers at cs.mu.oz.au
Administrative Queries: owner-mercury-developers at cs.mu.oz.au
Subscriptions: mercury-developers-request at cs.mu.oz.au
--------------------------------------------------------------------------
More information about the developers
mailing list