Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
R
relibc
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
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
Peter Limkilde Svendsen
relibc
Commits
40d01d9d
Verified
Commit
40d01d9d
authored
5 years ago
by
jD91mZM2
Browse files
Options
Downloads
Patches
Plain Diff
Convert printf internals to iterator
parent
c2c8806f
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
include.sh
+15
-3
15 additions, 3 deletions
include.sh
src/header/stdio/printf.rs
+362
-241
362 additions, 241 deletions
src/header/stdio/printf.rs
src/platform/redox/mod.rs
+0
-2
0 additions, 2 deletions
src/platform/redox/mod.rs
with
377 additions
and
246 deletions
include.sh
+
15
−
3
View file @
40d01d9d
#!/usr/bin/env bash
SUPRESS_ALL_THE_ERRORS
=
yes
set
-e
include
=
"
$(
realpath
"
$1
"
)
"
...
...
@@ -7,6 +9,10 @@ include="$(realpath "$1")"
cargo build
--release
--manifest-path
cbindgen/Cargo.toml
cbindgen
=
"
$(
realpath
target/release/cbindgen
)
"
if
[
"
$SUPRESS_ALL_THE_ERRORS
"
=
"yes"
]
;
then
echo
-e
"
\e
[91mNote: Warnings by cbindgen are suppressed in include.sh.
\e
[0m"
fi
jobs
=()
for
config
in
src/header/
*
/cbindgen.toml
do
...
...
@@ -15,10 +21,16 @@ do
if
[
"
${
name
:0:1
}
"
!=
"_"
]
then
header
=
"
$include
/
${
name
/_//
}
.h"
pushd
"
$dir
"
"
$cbindgen
"
-c
cbindgen.toml
-o
"
$header
"
mod.rs &
pushd
"
$dir
"
>
/dev/null
echo
"
$dir
"
cbindgen_cmd
=
'"$cbindgen" -c cbindgen.toml -o "$header" mod.rs'
if
[
"
$SUPRESS_ALL_THE_ERRORS
"
=
"yes"
]
;
then
eval
"
$cbindgen_cmd
"
2>&1 |
(
grep
"^ERROR"
-A
3
||
true
)
&
else
eval
"
$cbindgen_cmd
"
&
fi
jobs
+
=(
$!
)
popd
popd
>
/dev/null
fi
done
...
...
This diff is collapsed.
Click to expand it.
src/header/stdio/printf.rs
+
362
−
241
View file @
40d01d9d
This diff is collapsed.
Click to expand it.
src/platform/redox/mod.rs
+
0
−
2
View file @
40d01d9d
...
...
@@ -151,8 +151,6 @@ impl Pal for Sys {
mut
argv
:
*
const
*
mut
c_char
,
mut
envp
:
*
const
*
mut
c_char
,
)
->
c_int
{
use
alloc
::
vec
::
Vec
;
let
mut
file
=
match
File
::
open
(
path
,
fcntl
::
O_RDONLY
|
fcntl
::
O_CLOEXEC
)
{
Ok
(
file
)
=>
file
,
Err
(
_
)
=>
return
-
1
,
...
...
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