Coder Social home page Coder Social logo

Comments (4)

nemtrif avatar nemtrif commented on June 10, 2024

See #111 Basically a regression was introduced when fixing another issue.

Your options are:

  1. upgrade to 4.0.3
  2. Instead of using utf8::unchecked::utf16to8(), use utf8::utf16to8(). It is safer anyway and just a bit slower.

from utfcpp.

afh avatar afh commented on June 10, 2024

Thanks for the quick response, @nemtrif, very much appreciated 🙏
I'll talk with the other devs about (dis)advantages to using utf8::utf16to8() or maybe we can find a way to switch to it only for the affected releases of utfcpp.

I'd like to suggest to add a notice or warning to each the affected releases on its GitHub release page. Maybe something along the lines of:

This release introduces a breaking regression, please use at least 4.0.1. For details see #111.

from utfcpp.

nemtrif avatar nemtrif commented on June 10, 2024

No problem. My assumption they are using unchecked namespace to avoid exceptions. If so, you should better upgrade to 4.0.3. Or, just stay on a pre-3.2.5 release. 3.2.4 is OK.

from utfcpp.

afh avatar afh commented on June 10, 2024

Ledger will update to utfcpp 4.0.3 (ledger/ledger#2315 is pending review), yet some distributions, like Debian, prefer programs to link to libutfcpp rather than embed it. In the case where a distro ships libutfcpp 3.2.5 a sensible path forward is to apply a patch replacing uses of utf8::unchecked::utf16to8() with utf8::utf16to8() before compiling the program for the distribution package.

Your comments have been very helpful! 💯🙏

from utfcpp.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.