Inquiry with file node-addon-examples/5_function_factory/node_0.12/addon.cc
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 4/5
- Tempo estimado
- 3-5 dias
- Facilidade para iniciantes
- 25/100
Direção de pesquisa
Start with node-addon-examples/5_function_factory/node_0.12/addon.cc and review how the function factory example supplies its callback. The issue does not define a concrete repository change or a done condition; first determine whether the example or its documentation should explain using a private C++ member function, then identify an appropriate example or documentation test if one exists.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
Hi, anyone reading this,
The file node-addon-examples/5_function_factory/node_0.12/addon.cc contains a function factory, that's all well and good, but when I do something similiar, instead of using a global function, I'm using an instance function, (sorry, bad C++ vocab, I'm only new...) a function that's a private member of a class, and I want to use that as the function body, where the example uses
void MyFunction(const FunctionCallbackInfo<Value>& args) {
Isolate* isolate = Isolate::GetCurrent();
HandleScope scope(isolate);
args.GetReturnValue().Set(String::NewFromUtf8(isolate, "hello world"));
}
as the body. The issue is I get an error when doing this, the error is as follows: error C3867: 'Class::SampleFunction': non-standard syntax; use '&' to create a pointer to member and I have no idea what to do about it.
- Linguagem predominante
- C++
- Estrelas
- 2.6k
- Forks
- 598
- Métricas de merge de PRs
- Nenhum PR com merge em 30d
Preparar o ambiente
- Sem Dockerfile nem arquivo Docker Compose
- Tem um modelo de pull request
- Ler o guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de nodejs/node-addon-examples
-
Create Valgrind run of testsAbertaenhancement
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 38/100
nodejs/node-addon-examples#585 · 1 reação ·
-
Add .d.ts files in samples.Aberta
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 38/100
nodejs/node-addon-examples#530 · 1 comentário ·
-
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 35/100
nodejs/node-addon-examples#445 ·
-
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 32/100
nodejs/node-addon-examples#444 · 1 comentário ·
-
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 35/100
nodejs/node-addon-examples#381 ·
Todas as issues de nodejs/node-addon-examples
Issues semelhantes
-
`BLMPOP` with COUNT 0 or numkeys 0 hangsTalvez já em andamento @ggyuchive assumiu hoje. Abertabug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
Mantenedores costumam responder em até 1 dia
-
needs triage
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
Mantenedores costumam responder em até 1 dia
-
gObjectFullbrightAlphaMaskProgram in newview/llviewershadermgr.cpp is defined but never initializedAbertabug triage
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 78/100
secondlife/viewer#6620 ·
Mantenedores costumam responder em até 1 dia
-
bug core p3
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
RunanywhereAI/runanywhere-sdks#1258 ·
Mantenedores costumam responder em até 1 dia
-
ripwire-router skill: stale language list (15 vs 26 supported; Elixir/PHP/Kotlin wrongly listed as unsupported)Talvez já em andamento @joyful-ii-V-I assumiu hoje. Aberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 80/100
redhat-et/ripwire#521 · 1 comentário ·
Mantenedores costumam responder em até 1 dia