Add function to encode global identifier

This commit is contained in:
Sasha Koshka 2024-01-27 01:47:52 +00:00
parent 6fd0d600e2
commit f39edcca0c
1 changed files with 5 additions and 1 deletions

View File

@ -117,10 +117,14 @@ func EncodeRegisterName (name string) string {
return "%" + EscapeIdent(name)
}
func EncodeFunctionName (name string) string {
func EncodeGlobalName (name string) string {
return "@" + EscapeIdent(name)
}
func EncodeFunctionName (name string) string {
return EncodeGlobalName(name)
}
func EncodeLabelName (name string) string {
return EscapeIdent(name) + ":"
}