Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
jami-daemon
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Issue analytics
Insights
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
savoirfairelinux
jami-daemon
Commits
d1829197
Commit
d1829197
authored
3 years ago
by
Olivier Dion
Committed by
Adrien Béraud
3 years ago
Browse files
Options
Downloads
Patches
Plain Diff
agent/utils: Add from_guile()::operator uint8_t()
Change-Id: I00df0524c8b00ad55fffe1ab17e82ba8a8ee9c0a
parent
282a5e62
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
test/agent/src/utils.h
+7
-0
7 additions, 0 deletions
test/agent/src/utils.h
with
7 additions
and
0 deletions
test/agent/src/utils.h
+
7
−
0
View file @
d1829197
...
...
@@ -138,6 +138,13 @@ struct from_guile
return
scm_to_bool
(
value
);
}
operator
uint8_t
()
{
ensure_type
(
"uint8"
,
[](
SCM
v
){
return
scm_is_unsigned_integer
(
v
,
0
,
255
);
});
return
scm_to_int
(
value
);
}
operator
int
()
{
ensure_type
(
"integer"
,
scm_is_integer
);
...
...
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