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
c47259c7
Commit
c47259c7
authored
4 years ago
by
Florian Prill
Browse files
Options
Downloads
Patches
Plain Diff
[event_generic_review] example call to print_number.
parent
29599513
No related branches found
No related tags found
1 merge request
!3
WIP: Event generic
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
examples/int_div_example.c
+7
-0
7 additions, 0 deletions
examples/int_div_example.c
include/int_div.h
+0
-3
0 additions, 3 deletions
include/int_div.h
src/int_div.c
+1
-3
1 addition, 3 deletions
src/int_div.c
with
8 additions
and
6 deletions
examples/int_div_example.c
+
7
−
0
View file @
c47259c7
...
...
@@ -88,6 +88,13 @@ int main(void) {
#ifdef HAVE_GMP
printf
(
" %d discrepancies reported.
\n
"
,
cnt
);
#endif
/* additional calls (test interfaces). */
t_number
p1
;
/* dividend */
convert_basis
(
day_fraction1
*
(
t_int
)
20
,
&
p1
,
2
,
0
);
convert_basis
(
days1
,
&
p1
,
W_DIGITS
-
3
,
3
);
print_number
(
p1
);
printf
(
"test program done after %d tests.
\n
"
,
NREPEAT
);
exit
(
0
);
}
...
...
This diff is collapsed.
Click to expand it.
include/int_div.h
+
0
−
3
View file @
c47259c7
...
...
@@ -25,10 +25,7 @@ typedef int64_t t_int;
typedef
t_int
t_number
[
W_DIGITS
+
1
];
#ifdef DEBUG
void
print_number
(
const
t_number
x
);
#endif
void
number_init
(
t_number
*
x
,
const
t_int
val
,
const
unsigned
int
m
);
unsigned
int
length
(
const
t_number
x
);
void
product
(
t_number
*
x
,
const
t_number
y
,
const
t_int
k
,
const
t_int
b
,
int
*
ret
);
...
...
This diff is collapsed.
Click to expand it.
src/int_div.c
+
1
−
3
View file @
c47259c7
...
...
@@ -240,8 +240,6 @@ int divide_timespan(const t_int days1, const t_int day_fraction1,
}
#ifdef DEBUG
#include
<stdio.h>
#include
<inttypes.h>
...
...
@@ -252,4 +250,4 @@ void print_number(const t_number x) {
printf
(
"%"
PRId64
" "
,
x
[
i
]);
printf
(
"
\n
"
);
}
#endif
This diff is collapsed.
Click to expand it.
Florian Prill
@m300196
mentioned in merge request
!3 (closed)
·
4 years ago
mentioned in merge request
!3 (closed)
mentioned in merge request !3
Toggle commit list
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