Skip to content

Commit

Permalink
man3: luaL_optlstring.3
Browse files Browse the repository at this point in the history
  • Loading branch information
ligurio committed Jul 27, 2022
1 parent d9adcdd commit 1cb6caa
Showing 1 changed file with 32 additions and 0 deletions.
32 changes: 32 additions & 0 deletions man3/luaL_optlstring.3
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
.Dd $Mdocdate: July 26 2022 $
.Dt LUAL_OPTLSTRING 3
.Os
.Sh NAME
.Nm luaL_optlstring
.Nd if the function argument is a string, returns this string
.Sh SYNOPSIS
.In lauxlib.h
.Ft const char *
.Fn luaL_optlstring "lua_State *L" "int narg" "const char *d" "size_t *l"
.Sh DESCRIPTION
.Fn luaL_optlstring
if the function argument
.Fa narg
is a string, returns this string.
If this argument is absent or is
.Dv nil ,
returns
.Fa d .
Otherwise, raises an error.
.Pp
If
.Fa l
is not
.Dv NULL ,
fills the position
.Fa *l
with the results's length.
.Sh HISTORY
The
.Fn luaL_optlstring
manual page was written by Sergey Bronnikov.

0 comments on commit 1cb6caa

Please sign in to comment.