We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ef8e855 commit 2bfbe75Copy full SHA for 2bfbe75
library/src/scala/runtime/LazyVals.scala
@@ -142,6 +142,14 @@ object LazyVals {
142
r
143
}
144
145
+ def getStaticFieldOffset(field: java.lang.reflect.Field): Long = {
146
+ @nowarn
147
+ val r = unsafe.staticFieldOffset(field)
148
+ if (debug)
149
+ println(s"getStaticFieldOffset(${field.getDeclaringClass}, ${field.getName}) = $r")
150
+ r
151
+ }
152
+
153
def getOffsetStatic(field: java.lang.reflect.Field) =
154
@nowarn
155
val r = unsafe.objectFieldOffset(field)
0 commit comments