Skip to content

Swift-Demangler-in-Go/swift-demangle

Repository files navigation

English | CN中文

Visualization of the codebase

一、Swift Demangler in Go

1、What is it?

This is a Swift Fuction (:neutral_face: em, yes, just Swift Function right now) Demangler. You can simply import this package and demangle your mangled swift symbols:rocket:

二、Detail

1、Installation

  • Go >= 1.5

2、Usage

  • install this package
go get -u github.com/Swift-Demangler-in-Go/swift-demangle
  • import this package
import swiftDemangle "github.com/Swift-Demangler-in-Go/swift-demangle"
  • Usage Example
package main

import (
	"fmt"

	swiftDemangle "github.com/Swift-Demangler-in-Go/swift-demangle"
)

func main() {
	symbol, err := swiftDemangle.ToString("_TFC4Pack5class4FuncFSSSb")
	if err != nil {
		panic(err)
	}
	fmt.Println(symbol)
}

output:

Pack.class.Func(Swift.String) -> Swift.Bool
  • Make sure that your input is legal, or it would possibly fall into a dead circle.

About

A go module made for Swift mangling

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages