Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
go
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
go
Commits
999b12c7
Commit
999b12c7
authored
Jul 07, 2008
by
Ken Thompson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
remove incorrect (!) consts
-r SVN=126198
parent
5b904a3b
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
11 deletions
+11
-11
src/lib9/utf/utf.h
src/lib9/utf/utf.h
+6
-6
src/lib9/utf/utfrrune.c
src/lib9/utf/utfrrune.c
+2
-2
src/lib9/utf/utfrune.c
src/lib9/utf/utfrune.c
+3
-3
No files found.
src/lib9/utf/utf.h
View file @
999b12c7
...
...
@@ -123,7 +123,7 @@ int utfnlen(const char* s, long n);
// byte terminating a string is considered to be part of the string s.
// (cf. strchr)
const
char
*
utfrune
(
const
char
*
s
,
Rune
r
);
/*const*/
char
*
utfrune
(
const
char
*
s
,
Rune
r
);
// utfrrune returns a pointer to the last occurrence of rune r in the
...
...
@@ -131,7 +131,7 @@ const char* utfrune(const char* s, Rune r);
// byte terminating a string is considered to be part of the string s.
// (cf. strrchr)
const
char
*
utfrrune
(
const
char
*
s
,
Rune
r
);
/*const*/
char
*
utfrrune
(
const
char
*
s
,
Rune
r
);
// utfutf returns a pointer to the first occurrence of the UTF string
...
...
src/lib9/utf/utfrrune.c
View file @
999b12c7
...
...
@@ -16,7 +16,7 @@
#include "utf.h"
#include "utfdef.h"
const
/* const - removed for go code */
char
*
utfrrune
(
const
char
*
s
,
Rune
c
)
{
...
...
@@ -32,7 +32,7 @@ utfrrune(const char *s, Rune c)
c1
=
*
(
uchar
*
)
s
;
if
(
c1
<
Runeself
)
{
/* one byte rune */
if
(
c1
==
0
)
return
s1
;
return
(
char
*
)
s1
;
if
(
c1
==
c
)
s1
=
s
;
s
++
;
...
...
src/lib9/utf/utfrune.c
View file @
999b12c7
...
...
@@ -16,7 +16,7 @@
#include "utf.h"
#include "utfdef.h"
const
/* const - removed for go code */
char
*
utfrune
(
const
char
*
s
,
Rune
c
)
{
...
...
@@ -33,13 +33,13 @@ utfrune(const char *s, Rune c)
if
(
c1
==
0
)
return
0
;
if
(
c1
==
c
)
return
s
;
return
(
char
*
)
s
;
s
++
;
continue
;
}
n
=
chartorune
(
&
r
,
s
);
if
(
r
==
c
)
return
s
;
return
(
char
*
)
s
;
s
+=
n
;
}
return
0
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment