Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/wengchaoxi/gobf
一个用 Go 写的可扩展的 BrainFuck 语言的解释器。( An extensible Brainfuck interpreter written in Go. )
https://github.com/wengchaoxi/gobf
brainfuck go
Last synced: 22 days ago
JSON representation
一个用 Go 写的可扩展的 BrainFuck 语言的解释器。( An extensible Brainfuck interpreter written in Go. )
- Host: GitHub
- URL: https://github.com/wengchaoxi/gobf
- Owner: wengchaoxi
- Created: 2022-09-30T13:28:08.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2022-09-30T13:32:07.000Z (about 2 years ago)
- Last Synced: 2024-06-21T03:30:43.239Z (5 months ago)
- Topics: brainfuck, go
- Language: Go
- Homepage:
- Size: 2.93 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Go-BF
An extensible [Brainfuck](https://en.wikipedia.org/wiki/Brainfuck) interpreter written in Go.
# Example
```go
package mainimport (
"strings"
framework "github.com/wengchaoxi/gobf"
)func UnixTidyPlugin(program string) string {
return strings.ReplaceAll(program, "\n", "")
}func WindowsTidyPlugin(program string) string {
return strings.ReplaceAll(program, "\r\n", "")
}func main() {
t := framework.NewTape(1024)
m := framework.NewMachine(t)// DO WHAT THE FUCK YOU WANT TO
m.Use(UnixTidyPlugin, WindowsTidyPlugin)m.Run("+[,.]\n")
}
```