mirror of
https://github.com/revanced/smali.git
synced 2025-05-16 22:17:07 +02:00
use java's assert
git-svn-id: https://smali.googlecode.com/svn/trunk@411 55b6fa8a-2a1e-11de-a435-ffa8d773f76a
This commit is contained in:
parent
83e6f4bb60
commit
eb21bb1783
@ -28,12 +28,10 @@
|
||||
|
||||
package org.jf.dexlib.Util;
|
||||
|
||||
import junit.framework.Assert;
|
||||
|
||||
public abstract class AlignmentUtils {
|
||||
public static int alignOffset(int offset, int alignment) {
|
||||
int mask = alignment - 1;
|
||||
Assert.assertFalse("bogus alignment", (alignment < 0) || ((mask & alignment) != 0));
|
||||
assert (alignment >= 0) && ((mask & alignment) == 0);
|
||||
return (offset + mask) & ~mask;
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user