Rescope raylib.h into raylib::impl namespace
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 45/100
Direzione di ricerca
Start in the raylib-cpp include wrapper and inspect how raylib.h is included, along with the scope operators that refer to its declarations. Check whether the existing extern "C" guards in raylib.h cover the include, then verify that the header can be moved into raylib::impl without global namespace pollution or broken references.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Currently, the following code is included outside of namespace raylib, which pollutes the global namespace with raylib functions and types which can occasionally cause collisions. Is it possible to move this include into the raylib namespace? Many of the scope operators will have to be adjusted but I think this might result in some cleaner code. Also, I believe that the __cplusplus guards are not necessary when directly including a c header. I think this is typically used around C code that can be compiled by both a c & c++ compiler. The extern "C" is definitely still necessary though. Apologies if I am missing something.
https://isocpp.org/wiki/faq/mixing-c-and-cpp#include-c-hdrs-system
#ifdef __cplusplus
extern "C" {
#endif
#include "raylib.h"
#ifdef __cplusplus
}
#endif
Edit: extern "C" guards are in raylib.h already. It does not appear that it is necessary to include it in raylib-cpp
- Lingua principale
- C++
- Stelle
- 960
- Fork
- 120
- Merge medio
- 10m
- PR unite (30g)
- 1
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di RobLoach/raylib-cpp
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
RobLoach/raylib-cpp#425 ·
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 35/100
RobLoach/raylib-cpp#427 ·
-
Code gen Aperta
Difficoltà 5/5 Più di una settimana Idoneità per principianti 30/100
RobLoach/raylib-cpp#415 · 1 commento ·
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 45/100
RobLoach/raylib-cpp#370 · 1 commento ·
-
SDF Font Support Aperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 55/100
RobLoach/raylib-cpp#366 · 3 commenti ·
Tutte le issue di RobLoach/raylib-cpp
Issue simili
-
ai_reviewed
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
ydb-platform/ydb#53869 · 3 commenti ·
-
bug cert blocker needs triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
project-chip/connectedhomeip#74373 ·
-
[request] tracy/0.14.1 Apertaupstream update
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
conan-io/conan-center-index#31035 ·
-
Bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
-
documentation
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 85/100
vllm-project/vllm-ascend#17329 ·