Construct an asset handle from a relative sketch path at runtime. For **compile-time rejection** of `..` paths, use the `FL_ASSET()` macro instead — it wraps this function with `FL_STATIC_ASSERT`. This overload accepts any `const char*` (including runtime-computed pointers) and, for safety, returns an empty handle if the path contains a `..` segment. Runtime resolution also refuses to walk past
| 126 | /// a `..` segment. Runtime resolution also refuses to walk past `data/`, so |
| 127 | /// this is defense-in-depth rather than the primary gate. |
| 128 | constexpr asset_ref asset(const char* path) FL_NOEXCEPT { |
| 129 | return asset_detail::path_has_parent_segment(path) |
| 130 | ? asset_ref() |
| 131 | : asset_ref(path, asset_detail::clen(path)); |
| 132 | } |
| 133 | |
| 134 | /// Preferred entry point: rejects `..` at compile time via `FL_STATIC_ASSERT`. |
| 135 | /// |
no test coverage detected