Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
3dedcf82
Commit
3dedcf82
authored
May 17, 2019
by
Nikolay Sivov
Committed by
Alexandre Julliard
May 17, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernelbase: Use a helper to get character C1 type.
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
f010569c
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
18 deletions
+13
-18
string.c
dlls/kernelbase/string.c
+13
-18
No files found.
dlls/kernelbase/string.c
View file @
3dedcf82
...
...
@@ -28,6 +28,13 @@
WINE_DEFAULT_DEBUG_CHANNEL
(
string
);
static
WORD
get_char_type
(
WCHAR
ch
)
{
WORD
type
=
0
;
GetStringTypeW
(
CT_CTYPE1
,
&
ch
,
1
,
&
type
);
return
type
;
}
DWORD
WINAPI
StrCmpCA
(
const
char
*
str
,
const
char
*
cmp
)
{
return
lstrcmpA
(
str
,
cmp
);
...
...
@@ -60,30 +67,22 @@ DWORD WINAPI StrCmpNICW(const WCHAR *str, const WCHAR *cmp, DWORD len)
BOOL
WINAPI
IsCharBlankW
(
WCHAR
wc
)
{
WORD
type
;
return
GetStringTypeW
(
CT_CTYPE1
,
&
wc
,
1
,
&
type
)
&&
(
type
&
C1_BLANK
);
return
!!
(
get_char_type
(
wc
)
&
C1_BLANK
);
}
BOOL
WINAPI
IsCharCntrlW
(
WCHAR
wc
)
{
WORD
type
;
return
GetStringTypeW
(
CT_CTYPE1
,
&
wc
,
1
,
&
type
)
&&
(
type
&
C1_CNTRL
);
return
!!
(
get_char_type
(
wc
)
&
C1_CNTRL
);
}
BOOL
WINAPI
IsCharDigitW
(
WCHAR
wc
)
{
WORD
type
;
return
GetStringTypeW
(
CT_CTYPE1
,
&
wc
,
1
,
&
type
)
&&
(
type
&
C1_DIGIT
);
return
!!
(
get_char_type
(
wc
)
&
C1_DIGIT
);
}
BOOL
WINAPI
IsCharPunctW
(
WCHAR
wc
)
{
WORD
type
;
return
GetStringTypeW
(
CT_CTYPE1
,
&
wc
,
1
,
&
type
)
&&
(
type
&
C1_PUNCT
);
return
!!
(
get_char_type
(
wc
)
&
C1_PUNCT
);
}
BOOL
WINAPI
IsCharSpaceA
(
CHAR
c
)
...
...
@@ -94,16 +93,12 @@ BOOL WINAPI IsCharSpaceA(CHAR c)
BOOL
WINAPI
IsCharSpaceW
(
WCHAR
wc
)
{
WORD
type
;
return
GetStringTypeW
(
CT_CTYPE1
,
&
wc
,
1
,
&
type
)
&&
(
type
&
C1_SPACE
);
return
!!
(
get_char_type
(
wc
)
&
C1_SPACE
);
}
BOOL
WINAPI
IsCharXDigitW
(
WCHAR
wc
)
{
WORD
type
;
return
GetStringTypeW
(
CT_CTYPE1
,
&
wc
,
1
,
&
type
)
&&
(
type
&
C1_XDIGIT
);
return
!!
(
get_char_type
(
wc
)
&
C1_XDIGIT
);
}
WCHAR
*
WINAPI
StrChrW
(
const
WCHAR
*
str
,
WCHAR
ch
)
...
...
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