Skip to content

Commit b0035e0

Browse files
committed
Merge remote-tracking branch 'origin/develop'
2 parents da6fbd1 + dae89ed commit b0035e0

File tree

723 files changed

+9173
-59118
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

723 files changed

+9173
-59118
lines changed

CMakeLists.txt

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,21 @@ if(APPLE)
5050
message("Parent project has set autowiring_USE_LIBCXX = OFF -> Build Autowiring using c++98")
5151
endif()
5252
endif()
53+
54+
# Install autoboost when using libstdc++
55+
if(autowiring_USE_LIBCXX)
56+
set(autowiring_INSTALL_AUTOBOOST OFF)
57+
else()
58+
set(autowiring_INSTALL_AUTOBOOST ON)
59+
endif()
5360
else()
5461
# Always use libc++ on other platforms
5562
set(autowiring_USE_LIBCXX ON)
63+
64+
# Don't install autoboost unless otherwise specified
65+
if(NOT DEFINED autowiring_INSTALL_AUTOBOOST)
66+
set(autowiring_INSTALL_AUTOBOOST OFF)
67+
endif()
5668
endif()
5769

5870
if(CMAKE_COMPILER_IS_GNUCC)
@@ -101,13 +113,6 @@ list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake-modules")
101113
include(AddPCH)
102114
include(ConditionalSources)
103115

104-
if(autowiring_BUILD_ARM)
105-
# Currently cannot build Autonet for ARM, so default this off on that platform
106-
set(AUTOWIRING_BUILD_AUTONET_DEFAULT OFF)
107-
else()
108-
set(AUTOWIRING_BUILD_AUTONET_DEFAULT ON)
109-
endif()
110-
111116
# We don't build tests unless we're being built by ourselves in our own source tree
112117
# When we're embedded in someone else's subtree, it's not likely that they will want
113118
# us to bring all of our unit tests in with us. Though, if they do desire this, they
@@ -220,7 +225,7 @@ if(NOT AUTOWIRING_IS_EMBEDDED)
220225
)
221226

222227
# Install autoboost headers
223-
if(NOT autowiring_USE_LIBCXX)
228+
if(autowiring_INSTALL_AUTOBOOST)
224229
install(
225230
DIRECTORY ${PROJECT_SOURCE_DIR}/contrib/autoboost/autoboost
226231
DESTINATION include

Doxyfile

Lines changed: 1127 additions & 1599 deletions
Large diffs are not rendered by default.

autowiring/AnySharedPointer.h

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,21 @@
1-
// Copyright (C) 2012-2014 Leap Motion, Inc. All rights reserved.
1+
// Copyright (C) 2012-2015 Leap Motion, Inc. All rights reserved.
22
#pragma once
33
#include "SharedPointerSlot.h"
44

5+
/// \file SharedPointerSlot.h
6+
/// \internal
7+
8+
/// AnySharedPointer
59
struct AnySharedPointer {
610
public:
711
AnySharedPointer(void);
812
AnySharedPointer(AnySharedPointer&& rhs);
9-
explicit AnySharedPointer(const AnySharedPointer& rhs);
13+
AnySharedPointer(const AnySharedPointer& rhs);
14+
AnySharedPointer(const SharedPointerSlot&& rhs);
15+
AnySharedPointer(const SharedPointerSlot& rhs);
1016

1117
template<class T>
12-
explicit AnySharedPointer(const std::shared_ptr<T>& rhs) {
18+
AnySharedPointer(const std::shared_ptr<T>& rhs) {
1319
// Delegate the remainder to the assign operation:
1420
new (m_space) SharedPointerSlotT<T>(rhs);
1521
}

autowiring/AutoCheckout.h

Lines changed: 0 additions & 81 deletions
This file was deleted.

autowiring/AutoConfig.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright (C) 2012-2014 Leap Motion, Inc. All rights reserved.
1+
// Copyright (C) 2012-2015 Leap Motion, Inc. All rights reserved.
22
#pragma once
33
#include "Autowired.h"
44
#include "AutoConfigManager.h"
@@ -9,6 +9,7 @@
99

1010
struct AnySharedPointer;
1111

12+
/// \internal
1213
/// <summary>
1314
/// Utility base type for configuration members
1415
/// </summary>

autowiring/AutoConfigManager.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright (C) 2012-2014 Leap Motion, Inc. All rights reserved.
1+
// Copyright (C) 2012-2015 Leap Motion, Inc. All rights reserved.
22
#pragma once
33
#include "autowiring_error.h"
44
#include "ConfigRegistry.h"

autowiring/AutoFilterDescriptor.h

Lines changed: 13 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
// Copyright (C) 2012-2014 Leap Motion, Inc. All rights reserved.
1+
// Copyright (C) 2012-2015 Leap Motion, Inc. All rights reserved.
22
#pragma once
33
#include "AnySharedPointer.h"
4-
#include "AutoPacket.h"
54
#include "auto_arg.h"
5+
#include "AutoFilterDescriptorInput.h"
66
#include "CallExtractor.h"
77
#include "Decompose.h"
88
#include "has_autofilter.h"
@@ -13,43 +13,7 @@ class AutoPacket;
1313
class Deferred;
1414

1515
/// <summary>
16-
/// AutoFilter argument disposition
17-
/// </summary>
18-
struct AutoFilterDescriptorInput {
19-
AutoFilterDescriptorInput(void) :
20-
is_input(false),
21-
is_output(false),
22-
is_shared(false),
23-
ti(nullptr)
24-
{}
25-
26-
template<class T>
27-
AutoFilterDescriptorInput(auto_arg<T>*) :
28-
is_input(auto_arg<T>::is_input),
29-
is_output(auto_arg<T>::is_output),
30-
is_shared(auto_arg<T>::is_shared),
31-
ti(&typeid(typename auto_arg<T>::id_type))
32-
{}
33-
34-
const bool is_input;
35-
const bool is_output;
36-
const bool is_shared;
37-
const std::type_info* const ti;
38-
39-
operator bool(void) const {
40-
return !!ti;
41-
}
42-
43-
template<class T>
44-
struct rebind {
45-
operator AutoFilterDescriptorInput() {
46-
return AutoFilterDescriptorInput((auto_arg<T>*)nullptr);
47-
}
48-
};
49-
};
50-
51-
/// <summary>
52-
/// The unbound part of an AutoFilter, includes everything except the AnySharedPointer
16+
/// The unbound part of an AutoFilter, includes everything except the AnySharedPointer representing the filter proper
5317
/// </summary>
5418
struct AutoFilterDescriptorStub {
5519
AutoFilterDescriptorStub(void) :
@@ -73,6 +37,10 @@ struct AutoFilterDescriptorStub {
7337
/// <summary>
7438
/// Constructs a new packet subscriber entry based on the specified call extractor and call pointer
7539
/// </summary>
40+
/// <param name="pType">The type of the underlying filter</param>
41+
/// <param name="pArgs">The inputs accepted by the filter</param>
42+
/// <param name="deferred">True if the filter is deferred</param>
43+
/// <param name="pCall">A pointer to the AutoFilter call routine itself</param>
7644
/// <remarks>
7745
/// The caller is responsible for decomposing the desired routine into the target AutoFilter call. The extractor
7846
/// is required to carry information about the type of the proper member function to be called; t_extractedCall is
@@ -88,7 +56,8 @@ struct AutoFilterDescriptorStub {
8856
{
8957
for(auto pArg = m_pArgs; *pArg; pArg++) {
9058
m_arity++;
91-
59+
60+
// time shifted arguments arn't required
9261
if (pArg->is_input)
9362
++m_requiredCount;
9463
}
@@ -295,11 +264,6 @@ struct AutoFilterDescriptor:
295264
m_autoFilter->reset();
296265
}
297266

298-
/// <returns>
299-
/// True if this subscriber instance is not empty.
300-
/// </returns>
301-
operator bool(void) const { return !empty(); }
302-
303267
/// <returns>True when both the AutoFilter method and subscriber instance are equal.</returns>
304268
bool operator==(const AutoFilterDescriptor& rhs) const {
305269
// AutoFilter methods are the same for all instances of a class,
@@ -351,8 +315,11 @@ class AutoFilterDescriptorSelect<T, false>:
351315
};
352316

353317
/// <summary>
354-
/// Utility routine to support the creation of an AutoFilterDescriptor from any member function
318+
/// Utility routine to support the creation of an AutoFilterDescriptor from T::AutoFilter
355319
/// </summary>
320+
/// <remarks>
321+
/// This method will return an empty descriptor in the case that T::AutoFilter is not defined
322+
/// </remarks>
356323
template<class T>
357324
AutoFilterDescriptor MakeAutoFilterDescriptor(const std::shared_ptr<T>& ptr) {
358325
return std::move(AutoFilterDescriptorSelect<T>(ptr).desc);
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
// Copyright (C) 2012-2015 Leap Motion, Inc. All rights reserved.
2+
#pragma once
3+
#include "auto_arg.h"
4+
#include <typeinfo>
5+
6+
/// <summary>
7+
/// AutoFilter argument disposition
8+
/// </summary>
9+
struct AutoFilterDescriptorInput {
10+
AutoFilterDescriptorInput(void) :
11+
is_input(false),
12+
is_output(false),
13+
is_shared(false),
14+
is_multi(false),
15+
ti(nullptr),
16+
tshift(0)
17+
{}
18+
19+
template<class T>
20+
AutoFilterDescriptorInput(auto_arg<T>*) :
21+
is_input(auto_arg<T>::is_input),
22+
is_output(auto_arg<T>::is_output),
23+
is_shared(auto_arg<T>::is_shared),
24+
is_multi(auto_arg<T>::is_multi),
25+
ti(&typeid(typename auto_arg<T>::id_type)),
26+
tshift(auto_arg<T>::tshift)
27+
{}
28+
29+
const bool is_input;
30+
const bool is_output;
31+
const bool is_shared;
32+
const bool is_multi;
33+
const std::type_info* const ti;
34+
const int tshift;
35+
36+
operator bool(void) const {
37+
return !!ti;
38+
}
39+
40+
template<class T>
41+
struct rebind {
42+
operator AutoFilterDescriptorInput() {
43+
return AutoFilterDescriptorInput((auto_arg<T>*)nullptr);
44+
}
45+
};
46+
};

autowiring/AutoFuture.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright (C) 2012-2014 Leap Motion, Inc. All rights reserved.
1+
// Copyright (C) 2012-2015 Leap Motion, Inc. All rights reserved.
22
#pragma once
33
#include "CoreThread.h"
44
#include "fast_pointer_cast.h"

autowiring/AutoInjectable.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
1-
// Copyright (C) 2012-2014 Leap Motion, Inc. All rights reserved.
1+
// Copyright (C) 2012-2015 Leap Motion, Inc. All rights reserved.
22
#pragma once
33
#include "AutoFuture.h"
44
#include "CoreContext.h"
5+
#include "index_tuple.h"
56

67
class AutoInjectableExpressionBase {
78
public:

0 commit comments

Comments
 (0)