runtime: move KeepAlive/SetFinalizer to common code
We don't support these yet so let's just put them in a central location. Once these functions are supported we can think about how to structure the code again.
Этот коммит содержится в:
родитель
398c284480
коммит
f3d0195d35
4 изменённых файлов: 8 добавлений и 24 удалений
|
@ -640,11 +640,3 @@ func dumpHeap() {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
func KeepAlive(x interface{}) {
|
||||
// Unimplemented. Only required with SetFinalizer().
|
||||
}
|
||||
|
||||
func SetFinalizer(obj interface{}, finalizer interface{}) {
|
||||
// Unimplemented.
|
||||
}
|
||||
|
|
|
@ -69,14 +69,6 @@ func GC() {
|
|||
// No-op.
|
||||
}
|
||||
|
||||
func KeepAlive(x interface{}) {
|
||||
// Unimplemented. Only required with SetFinalizer().
|
||||
}
|
||||
|
||||
func SetFinalizer(obj interface{}, finalizer interface{}) {
|
||||
// Unimplemented.
|
||||
}
|
||||
|
||||
func initHeap() {
|
||||
// preinit() may have moved heapStart; reset heapptr
|
||||
heapptr = heapStart
|
||||
|
|
|
@ -27,14 +27,6 @@ func GC() {
|
|||
// Unimplemented.
|
||||
}
|
||||
|
||||
func KeepAlive(x interface{}) {
|
||||
// Unimplemented. Only required with SetFinalizer().
|
||||
}
|
||||
|
||||
func SetFinalizer(obj interface{}, finalizer interface{}) {
|
||||
// Unimplemented.
|
||||
}
|
||||
|
||||
func initHeap() {
|
||||
// Nothing to initialize.
|
||||
}
|
||||
|
|
|
@ -87,3 +87,11 @@ func LockOSThread() {
|
|||
// Stub for now
|
||||
func UnlockOSThread() {
|
||||
}
|
||||
|
||||
func KeepAlive(x interface{}) {
|
||||
// Unimplemented. Only required with SetFinalizer().
|
||||
}
|
||||
|
||||
func SetFinalizer(obj interface{}, finalizer interface{}) {
|
||||
// Unimplemented.
|
||||
}
|
||||
|
|
Загрузка…
Создание таблицы
Сослаться в новой задаче