Update brace style.

Add braces around single-line blocks, and remove line breaks before
function-opening braces.

This resolves #537.
This commit is contained in:
Jason Evans
2017-01-15 16:56:30 -08:00
parent 5154ff32ee
commit c4c2592c83
119 changed files with 2971 additions and 3572 deletions

View File

@@ -14,32 +14,27 @@ bool arena_prof_accum(tsdn_t *tsdn, arena_t *arena, uint64_t accumbytes);
#if (defined(JEMALLOC_ENABLE_INLINE) || defined(JEMALLOC_ARENA_C_))
JEMALLOC_INLINE unsigned
arena_ind_get(const arena_t *arena)
{
arena_ind_get(const arena_t *arena) {
return (base_ind_get(arena->base));
}
JEMALLOC_INLINE void
arena_internal_add(arena_t *arena, size_t size)
{
arena_internal_add(arena_t *arena, size_t size) {
atomic_add_zu(&arena->stats.internal, size);
}
JEMALLOC_INLINE void
arena_internal_sub(arena_t *arena, size_t size)
{
arena_internal_sub(arena_t *arena, size_t size) {
atomic_sub_zu(&arena->stats.internal, size);
}
JEMALLOC_INLINE size_t
arena_internal_get(arena_t *arena)
{
arena_internal_get(arena_t *arena) {
return (atomic_read_zu(&arena->stats.internal));
}
JEMALLOC_INLINE bool
arena_prof_accum_impl(arena_t *arena, uint64_t accumbytes)
{
arena_prof_accum_impl(arena_t *arena, uint64_t accumbytes) {
cassert(config_prof);
assert(prof_interval != 0);
@@ -52,22 +47,22 @@ arena_prof_accum_impl(arena_t *arena, uint64_t accumbytes)
}
JEMALLOC_INLINE bool
arena_prof_accum_locked(arena_t *arena, uint64_t accumbytes)
{
arena_prof_accum_locked(arena_t *arena, uint64_t accumbytes) {
cassert(config_prof);
if (likely(prof_interval == 0))
if (likely(prof_interval == 0)) {
return (false);
}
return (arena_prof_accum_impl(arena, accumbytes));
}
JEMALLOC_INLINE bool
arena_prof_accum(tsdn_t *tsdn, arena_t *arena, uint64_t accumbytes)
{
arena_prof_accum(tsdn_t *tsdn, arena_t *arena, uint64_t accumbytes) {
cassert(config_prof);
if (likely(prof_interval == 0))
if (likely(prof_interval == 0)) {
return (false);
}
{
bool ret;