Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
libmtime
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
icon-libraries
libmtime
Commits
b5712a1b
Commit
b5712a1b
authored
6 years ago
by
Thomas Jahns
Browse files
Options
Downloads
Patches
Plain Diff
Inline trivial function.
parent
9944f0b1
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
include/mtime_datetime.h
+7
-2
7 additions, 2 deletions
include/mtime_datetime.h
src/mtime_datetime.c
+0
-20
0 additions, 20 deletions
src/mtime_datetime.c
with
7 additions
and
22 deletions
include/mtime_datetime.h
+
7
−
2
View file @
b5712a1b
...
...
@@ -71,8 +71,13 @@ int
getNoOfDaysInYearDateTime
(
struct
_datetime
*
dt
);
/*! \cond PRIVATE */
bool
testYearIsLeapYear
(
int64_t
year
);
static
inline
bool
testYearIsLeapYear
(
int64_t
year
)
{
bool
isLeapYear
=
!
(
year
%
400
)
||
((
year
%
100
)
&&
!
(
year
%
4
));
return
isLeapYear
;
}
struct
_datetime
*
convertDateToDateTime
(
struct
_date
*
d
,
struct
_datetime
*
dt_return
);
...
...
This diff is collapsed.
Click to expand it.
src/mtime_datetime.c
+
0
−
20
View file @
b5712a1b
...
...
@@ -336,26 +336,6 @@ else
}
/*! \cond PRIVATE */
/* Internal function. Test is year a leap year? */
bool
testYearIsLeapYear
(
int64_t
year
)
{
bool
flag
=
false
;
if
(
!
(
year
%
400
))
flag
=
true
;
else
if
(
!
(
year
%
100
))
flag
=
false
;
else
if
(
!
(
year
%
4
))
flag
=
true
;
else
flag
=
false
;
return
flag
;
}
/*
* NOTE: Internal and not doxyfied.
*
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment