• Stars
    star
    156
  • Rank 239,589 (Top 5 %)
  • Language
    Lua
  • License
    ISC License
  • Created almost 9 years ago
  • Updated over 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Serializes and deserializes Lua values with LuaJIT

bitser

Build Status Coverage Status

Serializes and deserializes Lua values with LuaJIT.

local bitser = require 'bitser'

bitser.register('someResource', someResource)
bitser.registerClass(SomeClass)

serializedString = bitser.dumps(someValue)
someValue = bitser.loads(serializedString)

Documentation can be found in USAGE.md.

Pull requests, bug reports and other feedback welcome! ❤️

Bitser is released under the ISC license (functionally equivalent to the BSD 2-Clause and MIT licenses).

Please note that bitser requires LuaJIT for its ffi library and JIT compilation. Without JIT, it may or may not run, but it will be much slower than usual. This primarily affects Android and iOS, because JIT is disabled on those platforms.

Why would I use this?

Because it's fast. Because it produces tiny output. Because the name means "snappier" or "unfriendlier" in Dutch. Because it's safe to use with untrusted data.

Because it's inspired by binser, which is great.

How do I use the benchmark thingy?

Download zero or more of binser.lua, ser.lua, smallfolk.lua, serpent.lua and MessagePack.lua, and run:

love .

You do need LÖVE for that.

You can add more cases in the folder cases/ (check out _new.lua), and add other serializers to the benchmark in main.lua. If you do either of those things, please send me a pull request!

You can register classes?

Yes. At the moment, bitser supports MiddleClass, SECL, hump.class, Slither and Moonscript classes (and probably some other class libraries by accident).

More Repositories

1

Ser

A fast, robust, richly-featured table serialisation library for Lua
Lua
74
star
2

richtext

A text and image layout library for LÖVE
Lua
43
star
3

Lady

Saving and loading LÖVE savegames, based on Ser
Lua
37
star
4

Smallfolk

A fast, robust, secure, richly-featured table serialisation library for Lua
Lua
21
star
5

deja

The Déjà Vu programming language
C
15
star
6

space

A small space shooter -- IN LÖVE
Lua
13
star
7

suzy

A three-dimensional esoteric programming language
Python
8
star
8

adventure

A text adventure library in Lua
Lua
8
star
9

luahub

A wrapper library to access the GitHub API from Lua
Lua
7
star
10

adv-menu

A more advanced in-game menu for PyGame
Python
6
star
11

wurm

A simple sqlite3-based ORM for Python
Python
5
star
12

base116676

Cram data in a small number of code points
Python
4
star
13

isle

an interesting scriping language, inspired by Ruby, Lua, Python and Déjà Vu
Python
4
star
14

loveify

Changes .zip or .tar.gz files as downloaded from GitHub to .love files
Python
3
star
15

gvx.github.com

gvx GitHub Userpage
CSS
2
star
16

lith

A minimal data description language
Python
2
star
17

platformplanet

A small platform game, based on the concept and code of SpaceFlight2D
Python
2
star
18

sanity

Pre- and postcondition checker for Python 3
Python
2
star
19

Conq-rer

A Risk-implementation in Löve
Lua
2
star
20

invader

A quick and arcade-ish space stragegy game
Lua
2
star
21

dejavu

Déjà Vu is a byte-compiled language, which mixes Python and Forth
Python
2
star
22

altworld

A semi-Wiki system.
Python
2
star
23

openlife

An extensible people simulation game. This project isn't dead, but this name is.
Python
2
star
24

tutorialsource

Several Python tutorials, pretending to be source code.
Python
2
star
25

spaceflight2d

A not-so-small 2D space shooter
Python
2
star
26

botweeter

IRC bots + Twitter. This is the "+".
Python
1
star
27

a-whiff-of-steam

A Whiff of Steam (updated from Codaset)
Lua
1
star
28

stork

Almost entirely unlike a bird, this is scene-oriented software for writing stories, made with PyKDE
1
star
29

lua-tarpit

A fork of Lua, making it into a Turing tarpit
C
1
star
30

skeme

A top-down scheme generator using pycairo
Python
1
star
31

kibot

Kibot Junior, a modular IRC bot for #kiru
Python
1
star
32

lazy-lith

A minimal lazy programming language based on Lith
Python
1
star
33

generate-html

Generate HTML5 with Python generators
Python
1
star
34

translit

A small transliteration and transformation application for Ubuntu
Python
1
star
35

dolpi

Dol Pi is a constructed (human) language
Python
1
star
36

vinix

A Vim clone that can read, edit and write ODT files | superseded by Ovic
Python
1
star
37

wrong

The Wrong content processor
Python
1
star