0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2025-03-13 21:10:32 +01:00

ircd::ctx: Expose stack_max() to public interface.

This commit is contained in:
Jason Volk 2018-04-19 16:07:46 -07:00
parent 35a1c62b1f
commit 1dcfff91a5
2 changed files with 8 additions and 0 deletions

View file

@ -49,6 +49,7 @@ namespace ircd::ctx
const uint64_t &id(const ctx &); // Unique ID for context
string_view name(const ctx &); // User's optional label for context
const size_t &stack_max(const ctx &); // Returns stack size allocated for ctx
const int64_t &notes(const ctx &); // Peeks at internal semaphore count
bool interruption(const ctx &); // Context was marked for interruption
bool finished(const ctx &); // Context function returned (or exception).

View file

@ -383,6 +383,13 @@ ircd::ctx::notes(const ctx &ctx)
return ctx.notes;
}
/// Returns the notification count for `ctx
const size_t &
ircd::ctx::stack_max(const ctx &ctx)
{
return ctx.stack_max;
}
/// Returns the developer's optional name literal for `ctx`
ircd::string_view
ircd::ctx::name(const ctx &ctx)