Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Tobias Hunger
qt-creator
Commits
a93b6256
Commit
a93b6256
authored
Dec 07, 2009
by
Roberto Raggi
Browse files
Compile with msvc.
parent
bdb4e48e
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/libs/cplusplus/LookupContext.cpp
View file @
a93b6256
...
...
@@ -41,18 +41,11 @@
#include <QtDebug>
QT_BEGIN_NAMESPACE
uint
qHash
(
const
CPlusPlus
::
LookupItem
&
key
)
{
const
uint
h1
=
qHash
(
key
.
type
().
type
());
const
uint
h2
=
qHash
(
key
.
lastVisibleSymbol
());
return
((
h1
<<
16
)
|
(
h1
>>
16
))
^
h2
;
}
QT_END_NAMESPACE
uint
CPlusPlus
::
qHash
(
const
CPlusPlus
::
LookupItem
&
key
)
{
return
QT_PREPEND_NAMESPACE
(
qHash
)(
key
);
const
uint
h1
=
QT_PREPEND_NAMESPACE
(
qHash
)(
key
.
type
().
type
());
const
uint
h2
=
QT_PREPEND_NAMESPACE
(
qHash
)(
key
.
lastVisibleSymbol
());
return
((
h1
<<
16
)
|
(
h1
>>
16
))
^
h2
;
}
using
namespace
CPlusPlus
;
...
...
src/libs/cplusplus/LookupContext.h
View file @
a93b6256
...
...
@@ -232,8 +232,10 @@ uint qHash(const CPlusPlus::LookupItem &result);
}
// end of namespace CPlusPlus
QT_BEGIN_NAMESPACE
uint
qHash
(
const
CPlusPlus
::
LookupItem
&
result
);
QT_END_NAMESPACE
#if defined(Q_CC_MSVC) && _MSC_VER <= 1300
//this ensures that code outside QmlJS can use the hash function
//it also a workaround for some compilers
inline
uint
qHash
(
const
CPlusPlus
::
LookupItem
&
item
)
{
return
CPlusPlus
::
qHash
(
item
);
}
#endif
#endif // CPLUSPLUS_LOOKUPCONTEXT_H
Write
Preview
Supports
Markdown
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