fn: lua_pushstring
[contents]

Contents

Syntax

The syntax for lua_pushstring calls is:

f++:  
lua_pushstring(string)

n++:  
@lua_pushstring(string)

Description

The lua_pushstring function takes a single string parameter and pushes the string on to the Lua stack, it is a binding for this function.

f++ example

Example of lua_pushstring being used with f++:

lua_pushstring("hello, world!")
lua_setglobal("str")
lua
{
	print(str)
}

n++ example

Example of lua_pushstring being used with n++:

@lua_pushstring("hello, world!")
@lua_setglobal("str")
@lua
{
	print(str)
}