xref: /freebsd/contrib/file/magic/Magdir/bytecode (revision db33c6f3ae9d1231087710068ee4ea5398aacca7)
1
2#------------------------------------------------------------
3# $File: bytecode,v 1.5 2023/02/20 16:25:05 christos Exp $
4# magic for various bytecodes
5
6# From: Mikhail Gusarov <dottedmag@dottedmag.net>
7# NekoVM (https://nekovm.org/) bytecode
80	string		NEKO	NekoVM bytecode
9>4	lelong		x	(%d global symbols,
10>8	lelong		x	%d global fields,
11>12	lelong		x	%d bytecode ops)
12!:mime	application/x-nekovm-bytecode
13
14# https://www.iana.org/assignments/media-types/application/vnd.resilient.logic
15# From: Benedikt Muessig <benedikt@resilient-group.de>
160	belong		0x07524c4d	Resilient Logic bytecode
17!:mime	application/vnd.resilient.logic
18>4	byte/16		x	\b, version %d
19>4	byte&0x0f	x	\b.%d
20
21# Guile file magic from <dalepsmith@gmail.com>
22# https://www.gnu.org/s/guile/
23# https://git.savannah.gnu.org/gitweb/?p=guile.git;f=libguile/_scm.h;hb=HEAD#l250
24
250	string	GOOF----	Guile Object
26>8	string	LE		\b, little endian
27>8	string	BE		\b, big endian
28>11	string	4		\b, 32bit
29>11	string	8		\b, 64bit
30>13	regex	.\\..		\b, bytecode v%s
31
32# Racket file magic
33# From: Haelwenn (lanodan) Monnier <contact+libmagic@hacktivis.me>
34# https://racket-lang.org/
35# https://github.com/racket/racket/blob/master/racket/src/expander/compile/write-linklet.rkt
360	string	#~
37>&0	pstring	x
38>>&0	pstring	racket
39>>>0	string	#~	Racket bytecode
40>>>>&0	pstring	x       (version %s)
41
42