Skip to content

Conversation

@4mmonium
Copy link
Contributor

@4mmonium 4mmonium commented Feb 20, 2022

This commit adds documentation on how to use Lua 5.4 and documents the
power patches provided by this new release. Most of the documentation
for this comes from the readme (https://github.com/gottfriedleibniz/lua/blob/luaglm/README.md),
'as is' and the lua-users Wiki: http://lua-users.org/wiki/LuaPowerPatches#LUA_54_patches

I tried to not modify any of the documentation, only adding certain
markdown styling and some extra explanation to specific terms which may not be
known to new users.

This commit adds documentation on how to use Lua 5.4 and documents the
power patches provided by this new release. Most of the documentation
for this comes from the readme (https://github.com/gottfriedleibniz/lua/blob/luaglm/README.md),
'as is' and the lua-users Wiki: http://lua-users.org/wiki/LuaPowerPatches#LUA_54_patches
I tried to not modify any of the documentation, only adding certain
markdown styling and some extra explanation to specific terms which may not be
known to new users.
@jaymo1011
Copy link
Contributor

Currently, FiveM is compiled with a different tree of LuaGLM that does not include all of the power patches gottfriedleibniz/lua:luaglm has and not all of them are enabled either :)

@4mmonium
Copy link
Contributor Author

Currently, FiveM is compiled with a different tree of LuaGLM that does not include all of the power patches gottfriedleibniz/lua:luaglm has and not all of them are enabled either :)

Thanks, I guess I will review this and remove any power patches that don't apply from the docs 😃


## Short Function Notation or Shorthand lambdas (5.4.2)

Syntactic sugar for writing concise anonymous functions of the form `|a, b,
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removing, couldn't find a reference to this

result = table.isfrozen(t)
```

## Save/restore readline history (5.4.2)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This and Advanced readline support (5.4, 5.3, 5.2, 5.1, 5.0) aren't enabled, GRIT_POWER_READLINE_HISTORY isn't set in the defines.

- Remove shorthand lambda stuff (doesn't exist).
- Remove Save/restore readline history (5.4.2).
- Remove Advanced readline support (5.4, 5.3, 5.2, 5.1, 5.0).
- Remove 'Readonly' (for tables, which doesn't exist).
- Add functions for string blobs.
- Add section for nanosecond resolution timers with example code.

Thanks to @jaymo1011 for the help.
@AvarianKnight AvarianKnight added waiting for review PR needs to be reviewed draft and removed waiting for review PR needs to be reviewed labels Aug 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants