Added exe package to manage sections
This commit is contained in:
@ -1,7 +0,0 @@
|
||||
package fs
|
||||
|
||||
// Align calculates the next aligned address and the padding needed.
|
||||
func Align[T int | uint | int64 | uint64 | int32 | uint32](n T, alignment T) (T, T) {
|
||||
aligned := (n + (alignment - 1)) & ^(alignment - 1)
|
||||
return aligned, aligned - n
|
||||
}
|
Reference in New Issue
Block a user