Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
C
capnproto
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
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
capnproto
Commits
5bec541e
Commit
5bec541e
authored
May 31, 2013
by
Kenton Varda
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tweaks
parent
4cbb1a4d
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
6 additions
and
14 deletions
+6
-14
array-test.c++
c++/src/kj/array-test.c++
+1
-1
array.c++
c++/src/kj/array.c++
+0
-1
common.c++
c++/src/kj/common.c++
+0
-5
io.c++
c++/src/kj/io.c++
+1
-1
io.h
c++/src/kj/io.h
+4
-4
type-safety.h
c++/src/kj/type-safety.h
+0
-2
No files found.
c++/src/kj/array-test.c++
View file @
5bec541e
...
...
@@ -153,7 +153,7 @@ TEST(Array, AraryBuilder) {
{
ArrayBuilder
<
TestObject
>
builder
=
heapArrayBuilder
<
TestObject
>
(
32
);
for
(
u
int
i
=
0
;
i
<
32
;
i
++
)
{
for
(
int
i
=
0
;
i
<
32
;
i
++
)
{
EXPECT_EQ
(
i
,
TestObject
::
count
);
builder
.
add
();
}
...
...
c++/src/kj/array.c++
View file @
5bec541e
...
...
@@ -22,7 +22,6 @@
// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "array.h"
#include <iostream>
namespace
kj
{
...
...
c++/src/kj/common.c++
View file @
5bec541e
...
...
@@ -23,7 +23,6 @@
#include "common.h"
#include "logging.h"
#include <stdlib.h>
namespace
kj
{
namespace
internal
{
...
...
@@ -35,10 +34,6 @@ void inlinePreconditionFailure(const char* file, int line, const char* expectati
}
else
{
Log
::
fatalFault
(
file
,
line
,
Exception
::
Nature
::
PRECONDITION
,
expectation
,
macroArgs
,
message
);
}
// GCC prints a warning that this function returns even though Log::fatalFault() is clearly
// marked noreturn. Make the warning go away by calling abort()...
abort
();
}
}
// namespace internal
...
...
c++/src/kj/io.c++
View file @
5bec541e
...
...
@@ -25,7 +25,7 @@
#include "logging.h"
#include <unistd.h>
#include <sys/uio.h>
#include <
string
>
#include <
algorithm
>
namespace
kj
{
...
...
c++/src/kj/io.h
View file @
5bec541e
...
...
@@ -24,7 +24,7 @@
#ifndef KJ_IO_H_
#define KJ_IO_H_
#include <
cstddef
>
#include <
stddef.h
>
#include "common.h"
#include "array.h"
...
...
@@ -222,7 +222,7 @@ class AutoCloseFd {
public
:
inline
AutoCloseFd
()
:
fd
(
-
1
)
{}
inline
AutoCloseFd
(
std
::
nullptr_t
)
:
fd
(
-
1
)
{}
inline
AutoCloseFd
(
decltype
(
nullptr
)
)
:
fd
(
-
1
)
{}
inline
explicit
AutoCloseFd
(
int
fd
)
:
fd
(
fd
)
{}
inline
AutoCloseFd
(
AutoCloseFd
&&
other
)
:
fd
(
other
.
fd
)
{
other
.
fd
=
-
1
;
}
KJ_DISALLOW_COPY
(
AutoCloseFd
);
...
...
@@ -231,8 +231,8 @@ public:
inline
operator
int
()
{
return
fd
;
}
inline
int
get
()
{
return
fd
;
}
inline
bool
operator
==
(
std
::
nullptr_t
)
{
return
fd
<
0
;
}
inline
bool
operator
!=
(
std
::
nullptr_t
)
{
return
fd
>=
0
;
}
inline
bool
operator
==
(
decltype
(
nullptr
)
)
{
return
fd
<
0
;
}
inline
bool
operator
!=
(
decltype
(
nullptr
)
)
{
return
fd
>=
0
;
}
private
:
int
fd
;
...
...
c++/src/kj/type-safety.h
View file @
5bec541e
...
...
@@ -29,8 +29,6 @@
#define KJ_TYPE_SAFETY_H_
#include "common.h"
#include <cstddef>
#include <string.h>
namespace
kj
{
...
...
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