flashlight / text

Text utilities, including beam search decoding, tokenizing, and more, built for use in Flashlight.
MIT License
64 stars 14 forks source link

macOS - anonymous non-C-compatible type given name for linkage purposes by typedef declaration #69

Closed Athospd closed 1 year ago

Athospd commented 1 year ago

Hi, @jacobkahn, first of all, thank you for this package. I am building R bindings for flashlight-text and I would like to submit it to CRAN (the R's packages official repository).

Bug Description

The issue that I found is described here and pasted below. It is just a warning but it is preventing me to submit it to CRAN (which tolerates no warnings).

Found the following significant warnings:
/Users/runner/work/flashlighttext/flashlighttext/check/flashlighttext.Rcheck/00_pkg_src/
flashlighttext/src/build/kenlm/src/kenlm-project/lm/../util/joint_sort.hh:60:19: **warning: 
anonymous non-C-compatible type given name for linkage purposes by typedef declaration;** 
add a tag name here [-Wnon-c-typedef-for-linkage]
See ‘/Users/runner/work/flashlighttext/flashlighttext/check/flashlighttext.Rcheck/00install.out’ for details.
* used C++ compiler: ‘Apple clang version 14.0.0 (clang-1400.0.29.202)’

Is there anything we could do to make this warning go away? I would really appreciate it. By the way, I was just waiting to have it on CRAN to reach out to you to show the package working. It will expose the lib to the R users and, in the future, be used by the {torchaudio} package, the "R's pytorchaudio".

Platform and Hardware

I ran on OS macOS Monterey 12.6.5 (x86_64-apple-darwin20 (64-bit)); and compiler clang version 14.0.3 (clang-1403.0.22.14.1)

Thank you very much for your time!

Athospd commented 1 year ago

I made a huge confusion. This issue belogs to KenLM`s. Sorry!

jacobkahn commented 1 year ago

@Athospd — no problem! If a fix lands in KenLM and you want to update the commit hash in Flashlight Text, feel free to submit a PR!