Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
Consistent #include's in public VM APIs #35172
Currently, the #include's in runtime/include/*.h follow two formats:
#include "dart_api.h" #include "dart_tools_api.h"
This creates problems when we try to define the includes root. Currently, we have to put in both /runtime/ and /runtime/include as part of -I which seems unnecessary. Can we please standardize? I would much rather we always do #1 (w/o the "include" prefix).
Can you elaborate on why you prefer the first option.
We currently recommend users of this API to write #include "dart_api.h" in their code as opposed to "include/dart_api.h". The latter makes less sense to me since the prefix include/ is not specific to Dart VM.
These users, internally, depend on a single build target which defines the -I flag so they can't modify it. So we either need to tell them to use the include prefix OR have both runtime/ and runtime/include/ as part of -I.