diff options
| author | Dmitry Vyukov <dvyukov@google.com> | 2025-01-17 10:28:16 +0100 |
|---|---|---|
| committer | Dmitry Vyukov <dvyukov@google.com> | 2025-01-17 10:02:07 +0000 |
| commit | 5d04aae8969f6c72318ce0a4cde4f027766b1a55 (patch) | |
| tree | 8f1b632847c431407090f0fe1335522ff2195a37 /prog/prog.go | |
| parent | f9e07a6e597b68d3397864e6ee4550f9065c3518 (diff) | |
all: use min/max functions
They are shorter, more readable, and don't require temp vars.
Diffstat (limited to 'prog/prog.go')
| -rw-r--r-- | prog/prog.go | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/prog/prog.go b/prog/prog.go index ec899e35f..c9bd05baa 100644 --- a/prog/prog.go +++ b/prog/prog.go @@ -272,9 +272,7 @@ func (arg *GroupArg) Size() uint64 { offset += typ.AlignAttr - offset%typ.AlignAttr } } - if size < offset { - size = offset - } + size = max(size, offset) } return size case *ArrayType: |
