lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On Tue, Jul 7, 2009 at 10:06 AM, Martin<wtxnh-lua@yahoo.com.au> wrote:

> Is there a way to get hold of stdout without writing my own c-library?



require "alien"

alien.default.fprintf:types("int","pointer","string")

alien.default.fdopen:types("pointer","int","string")

local stdout=alien.default.fdopen(1,"w")

alien.default.fprintf(stdout,"hello world\n")


- Jeff