Skip to content

Port engine_xetex to Rust#1317

Draft
CraftSpider wants to merge 75 commits intotectonic-typesetting:masterfrom
CraftSpider:engine-port
Draft

Port engine_xetex to Rust#1317
CraftSpider wants to merge 75 commits intotectonic-typesetting:masterfrom
CraftSpider:engine-port

Conversation

@CraftSpider
Copy link
Copy Markdown
Contributor

@CraftSpider CraftSpider commented Aug 8, 2025

This is the big one - begin converting the engine into Rust.

CI clippy and Windows vcpkg are consistently failing. I'm leaving off fixing those till the end, as long as every other check is passing. vcpkg is a weird one in particular, it's related to a library on Windows not getting linked but that apparently works without these (non-build) changes. So I'm hoping removing most of the C code will just make it fix itself eventually.

@CraftSpider CraftSpider added the port-to-rust Replacing old code with Rust label Aug 8, 2025
@codecov
Copy link
Copy Markdown

codecov bot commented Aug 8, 2025

Codecov Report

❌ Patch coverage is 69.33925% with 1174 lines in your changes missing coverage. Please review.
✅ Project coverage is 30.14%. Comparing base (e8dd681) to head (baa7d6b).
⚠️ Report is 35 commits behind head on master.

Files with missing lines Patch % Lines
crates/engine_xetex/src/c_api/scaled_math.rs 31.71% 209 Missing and 2 partials ⚠️
crates/engine_xetex/src/c_api/output.rs 80.18% 131 Missing and 22 partials ⚠️
crates/engine_xetex/src/c_api/engine.rs 86.04% 127 Missing and 12 partials ⚠️
crates/engine_xetex/xetex/xetex-ini.c 69.77% 0 Missing and 123 partials ⚠️
crates/engine_xetex/xetex/xetex-xetexd.h 0.92% 0 Missing and 107 partials ⚠️
crates/engine_xetex/xetex/xetex-shipout.c 61.70% 3 Missing and 69 partials ⚠️
crates/engine_xetex/xetex/xetex-linebreak.c 58.57% 33 Missing and 37 partials ⚠️
crates/engine_xetex/src/c_api/engine/memory.rs 32.50% 54 Missing ⚠️
crates/engine_xetex/src/c_api/dvi.rs 69.40% 39 Missing and 2 partials ⚠️
crates/engine_xetex/src/c_api/errors.rs 70.19% 26 Missing and 5 partials ⚠️
... and 17 more
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1317      +/-   ##
==========================================
+ Coverage   28.85%   30.14%   +1.29%     
==========================================
  Files         273      282       +9     
  Lines      203491   180748   -22743     
  Branches   203491   180748   -22743     
==========================================
- Hits        58724    54495    -4229     
+ Misses      64143    54896    -9247     
+ Partials    80624    71357    -9267     
Components Coverage Δ
tectonic 51.15% <ø> (+0.26%) ⬆️
bridge_core 34.04% <88.88%> (-0.95%) ⬇️
bridge_flate 38.82% <ø> (ø)
bridge_fontconfig 96.17% <ø> (ø)
bridge_freetype2 92.70% <ø> (ø)
bridge_graphite2 42.47% <ø> (ø)
bridge_harfbuzz 82.83% <ø> (ø)
bridge_icu ∅ <ø> (∅)
bridge_png 100.00% <ø> (ø)
bundles 34.94% <ø> (+0.16%) ⬆️
cfg_support 94.84% <ø> (ø)
dep_support 0.00% <ø> (ø)
docmodel 84.61% <ø> (+0.51%) ⬆️
engine_bibtex 66.45% <ø> (ø)
engine_spx2html 0.00% <ø> (ø)
engine_xdvipdfmx 64.58% <ø> (+9.00%) ⬆️
engine_xetex 36.40% <69.20%> (+1.12%) ⬆️
errors 47.61% <ø> (ø)
geturl 28.20% <ø> (+1.04%) ⬆️
io_base 76.14% <ø> (+0.10%) ⬆️
pdf_io 14.17% <ø> (-0.15%) ⬇️
status_base 73.49% <ø> (+1.72%) ⬆️
xdv 55.28% <ø> (+0.06%) ⬆️
xetex_format 23.31% <ø> (+0.50%) ⬆️
xetex_layout 59.57% <ø> (+0.94%) ⬆️

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@CraftSpider CraftSpider force-pushed the engine-port branch 2 times, most recently from d2c1b60 to ca5f6b8 Compare April 19, 2026 03:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

port-to-rust Replacing old code with Rust

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant