Bug leads to crash program when using .set<T>() and then apply_visitor()
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 384
- Forks
- 96
- PR merge metrics
- No merged PRs in 30d
Description
#include
#include
#include
using namespace std;
using namespace mapbox::util;
// Forward declaration
struct HPArray;
struct HPTable;
using HPVariant = variant>;
struct HPArray{
template
HPArray(Args ...args){
values.emplace(std::forward(args)...);
}
unordered_map values;
};
struct Visitor{
void operator()(const string &str){
cout << str <(ar);
Visitor visitor;
apply_visitor(visitor,var);
return 0;
}
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Compile and run the C++ reproducer from the issue, then inspect the implementations of set() and apply_visitor(). Done means the example completes without crashing and the visitor handles the stored string and float values.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 38/100