/_debug

debug hints library

Primary LanguageLuaMIT LicenseMIT

Debug Hints Library

Copyright (C) 2002-2023 std._debug authors

License workflow status codecov.io

This is a debug hints management library for Lua 5.1 (including LuaJIT), 5.2, 5.3 and 5.4. The library is copyright by its authors (see the AUTHORS file for details), and released under the MIT license (the same license as Lua itself). There is no warranty.

std._debug has no run-time prerequisites beyond a standard Lua system.

Installation

The simplest and best way to install this library is with LuaRocks. To install the latest release (recommended):

    luarocks install std._debug

To install current git master (for testing, before submitting a bug report for example):

    luarocks install http://raw.githubusercontent.com/lua-stdlib/_debug/master/stdlib-git-1.rockspec

The best way to install without LuaRocks is to copy the std folder and its contents into a directory on your package search path.

Documentation

The latest release of these libraries is documented in LDoc. Pre-built HTML files are included in the release.

Bug reports and code contributions

These libraries are written and maintained by their users.

Please make bug reports and suggestions as GitHub Issues. Pull requests are especially appreciated.

But first, please check that your issue has not already been reported by someone else, and that it is not already fixed by master in preparation for the next release (see Installation section above for how to temporarily install master with LuaRocks).

There is no strict coding style, but please bear in mind the following points when proposing changes:

  1. Follow existing code. There are a lot of useful patterns and avoided traps there.

  2. 3-character indentation using SPACES in Lua sources: It makes rogue TABS easier to see, and lines up nicely with 'if' and 'end' keywords.

  3. Simple strings are easiest to type using single-quote delimiters, saving double-quotes for where a string contains apostrophes.

  4. Save horizontal space by only using SPACES where the parser requires them.

  5. Use vertical space to separate out compound statements to help the coverage reports discover untested lines.