Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
djinni
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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
cpp-libs
djinni
Commits
bca8b4b6
Commit
bca8b4b6
authored
Jun 09, 2017
by
Andrew Twyman
Committed by
GitHub
Jun 09, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #309 from msjarrett/cppfixes-201704
C++ fixes for compiler issues
parents
554a3b2b
c73950ed
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
4 deletions
+17
-4
CONTRIBUTORS
CONTRIBUTORS
+8
-0
support-lib/jni/djinni_support.hpp
support-lib/jni/djinni_support.hpp
+8
-4
support-lib/proxy_cache_interface.hpp
support-lib/proxy_cache_interface.hpp
+1
-0
No files found.
CONTRIBUTORS
0 → 100644
View file @
bca8b4b6
The following is a partial list of individuals or corporations
who have identified their contributions to the djinni project.
The complete list of contributors can be identified through
Git history.
- Google Inc.
support-lib/jni/djinni_support.hpp
View file @
bca8b4b6
...
@@ -156,11 +156,11 @@ void jniThrowAssertionError(JNIEnv * env, const char * file, int line, const cha
...
@@ -156,11 +156,11 @@ void jniThrowAssertionError(JNIEnv * env, const char * file, int line, const cha
#define DJINNI_ASSERT_MSG(check, env, message) \
#define DJINNI_ASSERT_MSG(check, env, message) \
do { \
do { \
djinni::jniExceptionCheck(env); \
::
djinni::jniExceptionCheck(env); \
const bool check__res = bool(check); \
const bool check__res = bool(check); \
djinni::jniExceptionCheck(env); \
::
djinni::jniExceptionCheck(env); \
if (!check__res) { \
if (!check__res) { \
djinni::jniThrowAssertionError(env, __FILE__, __LINE__, message); \
::
djinni::jniThrowAssertionError(env, __FILE__, __LINE__, message); \
} \
} \
} while(false)
} while(false)
#define DJINNI_ASSERT(check, env) DJINNI_ASSERT_MSG(check, env, #check)
#define DJINNI_ASSERT(check, env) DJINNI_ASSERT_MSG(check, env, #check)
...
@@ -340,7 +340,11 @@ template <class T>
...
@@ -340,7 +340,11 @@ template <class T>
static
const
std
::
shared_ptr
<
T
>
&
objectFromHandleAddress
(
jlong
handle
)
{
static
const
std
::
shared_ptr
<
T
>
&
objectFromHandleAddress
(
jlong
handle
)
{
assert
(
handle
);
assert
(
handle
);
assert
(
handle
>
4096
);
assert
(
handle
>
4096
);
const
auto
&
ret
=
reinterpret_cast
<
const
CppProxyHandle
<
T
>
*>
(
handle
)
->
get
();
// Below line segfaults gcc-4.8. Using a temporary variable hides the bug.
//const auto & ret = reinterpret_cast<const CppProxyHandle<T> *>(handle)->get();
const
CppProxyHandle
<
T
>
*
proxy_handle
=
reinterpret_cast
<
const
CppProxyHandle
<
T
>
*>
(
handle
);
const
auto
&
ret
=
proxy_handle
->
get
();
assert
(
ret
);
assert
(
ret
);
return
ret
;
return
ret
;
}
}
...
...
support-lib/proxy_cache_interface.hpp
View file @
bca8b4b6
...
@@ -16,6 +16,7 @@
...
@@ -16,6 +16,7 @@
#pragma once
#pragma once
#include <memory>
#include <functional>
#include <functional>
#include <typeindex>
#include <typeindex>
...
...
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