Comments (4)
@p-ranav I can confirm that building the samples using gcc (GCC) 12.2.1
from f03feac succeeds as opposed to f38bf22.
from indicators.
Thanks for reporting this issue and thanks for your patience.
I've rewritten the function without codecvt
and merged a fix. If the fix does not work, please reopen this issue.
if you confirm that the fix works for you, I'll go ahead and prepare a new release.
from indicators.
Just trying indicators for the first time, ran into same issue. codecvt_utf8 has been deprecated as of C++17. The solution is: "Users should use dedicated text-processing libraries instead." So, it appears the functionality needs to be incorporated into the library.
from indicators.
Another data point: this library doesn't compile on macOS 13 with Apple Clang 14. The reasons are the same; codecvt_utf8 has been removed from the standard library:
In file included from /Users/charles/src/indicators/samples/progress_bar_unicode.cpp:3:
In file included from /Users/charles/src/indicators/include/indicators/indeterminate_progress_bar.hpp:5:
In file included from /Users/charles/src/indicators/include/indicators/details/stream_helper.hpp:5:
/Users/charles/src/indicators/include/indicators/display_width.hpp:284:29: error: no member named 'codecvt_utf8' in namespace 'std'
std::wstring_convert<std::codecvt_utf8<wchar_t>> myconv;
~~~~~^
/Users/charles/src/indicators/include/indicators/display_width.hpp:284:49: error: expected '(' for function-style cast or type construction
std::wstring_convert<std::codecvt_utf8<wchar_t>> myconv;
~~~~~~~^
/Users/charles/src/indicators/include/indicators/display_width.hpp:284:50: error: expected unqualified-id
std::wstring_convert<std::codecvt_utf8<wchar_t>> myconv;
^
/Users/charles/src/indicators/include/indicators/display_width.hpp:285:10: error: use of undeclared identifier 'myconv'
return myconv.from_bytes(str);
^
/Users/charles/src/indicators/include/indicators/display_width.hpp:290:29: error: no member named 'codecvt_utf8' in namespace 'std'
std::wstring_convert<std::codecvt_utf8<wchar_t>> myconv;
~~~~~^
/Users/charles/src/indicators/include/indicators/display_width.hpp:290:49: error: expected '(' for function-style cast or type construction
std::wstring_convert<std::codecvt_utf8<wchar_t>> myconv;
~~~~~~~^
/Users/charles/src/indicators/include/indicators/display_width.hpp:290:50: error: expected unqualified-id
std::wstring_convert<std::codecvt_utf8<wchar_t>> myconv;
^
/Users/charles/src/indicators/include/indicators/display_width.hpp:291:10: error: use of undeclared identifier 'myconv'
return myconv.to_bytes(str);
from indicators.
Related Issues (20)
- warning: comparison is always false due to limited range of data type [-Wtype-limits]
- fit progress bar to terminal width changes? HOT 1
- Compile error
- No percentage indication on Windows HOT 2
- How to construct multiprogress with variable? HOT 2
- print to console HOT 2
- How to let indicator don't cover the print message? HOT 3
- Can i re-use a prior defined bar rather than define two separated bars? HOT 3
- [question] An `std::range_error` exception in `intermediate_progress_bar.cpp`.
- [bug] Cannot compile the sample codes with MSVC compiler on Windows.
- Passing boost::optional ProgressBar handle (from inside DynamicProgress) to function for mutation
- conversion to ‘float’ from ‘double’ may alter its value [-Werror=float-conversion]
- Block progress bar not working
- C++17 deprecated codecvt_utf8 breaks build on MSVC with C++20 HOT 3
- continuously spinning line appears to be missing
- Write DynamicProgress bar to stderr
- indicators changes locale HOT 1
- Dynamically set MaxProgress during iteration
- setlocale in utf8_decode will throw std::logic_error when setlocale returns NULL
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from indicators.