Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
U
uniset2
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
UniSet project repositories
uniset2
Commits
74b48077
Commit
74b48077
authored
Oct 09, 2022
by
Pavel Vainerman
Committed by
Pavel Vainerman
Oct 15, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
(timespec): fixed build for c++17
parent
07d6f94a
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
10 deletions
+9
-10
UniSetTypes.h
include/UniSetTypes.h
+8
-10
UniSetTypes.cc
src/Core/UniSetTypes.cc
+1
-0
No files found.
include/UniSetTypes.h
View file @
74b48077
...
...
@@ -184,16 +184,6 @@ namespace uniset
uniset
::
Timespec_var
to_uniset_timespec
(
const
std
::
chrono
::
system_clock
::
duration
&
d
);
uniset
::
Timespec_var
now_to_uniset_timespec
();
/*!< получение текущего времени */
inline
bool
operator
==
(
const
struct
timespec
&
r1
,
const
struct
timespec
&
r2
)
{
return
(
r1
.
tv_sec
==
r2
.
tv_sec
&&
r1
.
tv_nsec
==
r2
.
tv_nsec
);
}
inline
bool
operator
!=
(
const
struct
timespec
&
r1
,
const
struct
timespec
&
r2
)
{
return
!
(
operator
==
(
r1
,
r2
));
}
/*! Разбивка строки по указанному символу */
IDList
explode
(
const
std
::
string
&
str
,
char
sep
=
','
);
std
::
vector
<
std
::
string
>
explode_str
(
const
std
::
string
&
str
,
char
sep
=
','
);
...
...
@@ -361,4 +351,12 @@ namespace uniset
// -----------------------------------------------------------------------------------------
}
// end of namespace uniset
// -----------------------------------------------------------------------------------------
inline
bool
operator
==
(
const
struct
timespec
&
r1
,
const
struct
timespec
&
r2
)
{
return
(
r1
.
tv_sec
==
r2
.
tv_sec
&&
r1
.
tv_nsec
==
r2
.
tv_nsec
);
}
inline
bool
operator
!=
(
const
struct
timespec
&
r1
,
const
struct
timespec
&
r2
)
{
return
!
(
operator
==
(
r1
,
r2
));
}
#endif
src/Core/UniSetTypes.cc
View file @
74b48077
...
...
@@ -773,3 +773,4 @@ uint32_t uniset::hash32( const char* buf, size_t sz ) noexcept
{
return
NAMESPACE_FOR_HASH_FUNCTIONS
::
Hash32
(
buf
,
sz
);
}
// -------------------------------------------------------------------------
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