Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Q
qt-creator
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Tobias Hunger
qt-creator
Commits
58d06f52
Commit
58d06f52
authored
15 years ago
by
Erik Verbruggen
Browse files
Options
Downloads
Patches
Plain Diff
Manually reverted parts of
d61eb9c8
.
parent
9de8f384
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/shared/cplusplus/ObjectiveCTypeQualifiers.cpp
+13
-94
13 additions, 94 deletions
src/shared/cplusplus/ObjectiveCTypeQualifiers.cpp
src/shared/cplusplus/ObjectiveCTypeQualifiers.h
+0
-11
0 additions, 11 deletions
src/shared/cplusplus/ObjectiveCTypeQualifiers.h
with
13 additions
and
105 deletions
src/shared/cplusplus/ObjectiveCTypeQualifiers.cpp
+
13
−
94
View file @
58d06f52
...
...
@@ -32,88 +32,27 @@
using
namespace
CPlusPlus
;
static
inline
int
classify2
(
const
char
*
s
)
{
if
(
s
[
0
]
==
'N'
)
{
if
(
s
[
1
]
==
'O'
)
{
return
Token_NO
;
}
}
else
if
(
s
[
0
]
==
'i'
)
{
if
(
s
[
1
]
==
'd'
)
{
return
Token_id
;
}
else
if
(
s
[
1
]
==
'n'
)
{
return
Token_in
;
}
if
(
s
[
0
]
==
'i'
)
{
if
(
s
[
1
]
==
'n'
)
{
return
Token_in
;
}
return
Token_identifier
;
}
return
Token_identifier
;
}
static
inline
int
classify3
(
const
char
*
s
)
{
if
(
s
[
0
]
==
'I'
)
{
if
(
s
[
1
]
==
'M'
)
{
if
(
s
[
2
]
==
'P'
)
{
return
Token_IMP
;
}
}
}
else
if
(
s
[
0
]
==
'N'
)
{
if
(
s
[
1
]
==
'i'
)
{
if
(
s
[
2
]
==
'l'
)
{
return
Token_Nil
;
}
}
}
else
if
(
s
[
0
]
==
'S'
)
{
if
(
s
[
1
]
==
'E'
)
{
if
(
s
[
2
]
==
'L'
)
{
return
Token_SEL
;
}
}
}
else
if
(
s
[
0
]
==
'Y'
)
{
if
(
s
[
1
]
==
'E'
)
{
if
(
s
[
2
]
==
'S'
)
{
return
Token_YES
;
}
}
}
else
if
(
s
[
0
]
==
'n'
)
{
if
(
s
[
1
]
==
'i'
)
{
if
(
s
[
2
]
==
'l'
)
{
return
Token_nil
;
}
}
}
else
if
(
s
[
0
]
==
'o'
)
{
if
(
s
[
1
]
==
'u'
)
{
if
(
s
[
2
]
==
't'
)
{
return
Token_out
;
}
}
if
(
s
[
0
]
==
'o'
)
{
if
(
s
[
1
]
==
'u'
)
{
if
(
s
[
2
]
==
't'
)
{
return
Token_out
;
}
}
return
Token_identifier
;
}
return
Token_identifier
;
}
static
inline
int
classify4
(
const
char
*
s
)
{
if
(
s
[
0
]
==
'_'
)
{
if
(
s
[
1
]
==
'c'
)
{
if
(
s
[
2
]
==
'm'
)
{
if
(
s
[
3
]
==
'd'
)
{
return
Token__cmd
;
}
}
}
}
else
if
(
s
[
0
]
==
'B'
)
{
if
(
s
[
1
]
==
'O'
)
{
if
(
s
[
2
]
==
'O'
)
{
if
(
s
[
3
]
==
'L'
)
{
return
Token_BOOL
;
}
}
}
}
else
if
(
s
[
0
]
==
'c'
)
{
if
(
s
[
0
]
==
'c'
)
{
if
(
s
[
1
]
==
'o'
)
{
if
(
s
[
2
]
==
'p'
)
{
if
(
s
[
3
]
==
'y'
)
{
...
...
@@ -122,15 +61,6 @@ static inline int classify4(const char *s) {
}
}
}
else
if
(
s
[
0
]
==
's'
)
{
if
(
s
[
1
]
==
'e'
)
{
if
(
s
[
2
]
==
'l'
)
{
if
(
s
[
3
]
==
'f'
)
{
return
Token_self
;
}
}
}
}
return
Token_identifier
;
}
...
...
@@ -157,17 +87,6 @@ static inline int classify5(const char *s) {
}
}
}
else
if
(
s
[
0
]
==
's'
)
{
if
(
s
[
1
]
==
'u'
)
{
if
(
s
[
2
]
==
'p'
)
{
if
(
s
[
3
]
==
'e'
)
{
if
(
s
[
4
]
==
'r'
)
{
return
Token_super
;
}
}
}
}
}
return
Token_identifier
;
}
...
...
This diff is collapsed.
Click to expand it.
src/shared/cplusplus/ObjectiveCTypeQualifiers.h
+
0
−
11
View file @
58d06f52
...
...
@@ -35,22 +35,11 @@
namespace
CPlusPlus
{
enum
{
Token_NO
,
Token_id
,
Token_in
,
Token_YES
,
Token_IMP
,
Token_Nil
,
Token_SEL
,
Token_nil
,
Token_out
,
Token__cmd
,
Token_BOOL
,
Token_copy
,
Token_self
,
Token_byref
,
Token_inout
,
Token_super
,
Token_assign
,
Token_bycopy
,
Token_getter
,
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment