1// Copyright 2018 The Go Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style
3// license that can be found in the LICENSE file.
4
5package main
6
7import _ "unsafe" // for go:linkname
8
9func init() {
10	register("Abort", Abort)
11}
12
13//go:linkname runtimeAbort runtime.abort
14func runtimeAbort()
15
16func Abort() {
17	defer func() {
18		recover()
19		panic("BAD: recovered from abort")
20	}()
21	runtimeAbort()
22	println("BAD: after abort")
23}
24