Lua学习系列(一)
从现在开始,打算学习一门新的脚本语言-lua.
1.什么是lua?
a) lua1
• Lua 1.0 was implemented as a library, in less then 6000 lines of C
• “The simplest thing that could possibly work”: compiler used lex and yacc, simple stack based virtual machine, linked lists for associative arrays
• Some of the syntax still lives in the current version:
• Lua 1.1 just added a reference manual, and a cleaned-up C API
b)lua2
• From Lua 2.1 (February 1995) to Lua 2.5 (November 1996)
• Object oriented programming via delegation
• Pattern matching in the standard library
• Hooks for writing debuggers
• First users outside Tecgraf, with papers in Software: Practice and Experience and Dr. Dobb's Journal
• LucasArts begins using Lua in games
c)lua3
• From Lua 3.0 (September 1997) to Lua 3.2 (September de 1999)
• Anonymous functions and a restricted form of closures give better support for functional programming, which would mature in Lua 5
• Major refactoring in the source code
• The next version brings big changes to the C API, so some applications from this time still embed this version of Lua
d)lua4
• A single version, Lua 4.0, released on November 2000
• C API completely redone, using the stack model that we will see in this course
• An application can now have several independent instances of the Lua interpreter
• The standard library has been rewritten to use just the public C API, reinforcing the separation between the core and the standard libraries
e)lua5
• From Lua 5.0 (April 2003) to Lua 5.2, the current version, released December 2011
• Maturity of the language, and the release of the “Programming in Lua” book
• Several big changes: metatables, true lexical scope for anynonymous functions, the module system, coroutines, lexical environments…
• Changes in the implementation: more efficient register-based virtual machine, replacing the stack-based one, an incremental garbage collector for shorter pauses
• The implementation now has around 20.000 lines of code, 3x Lua 1.0
f)lua today
• Current license is the MIT license, free for both non-commercial and commercial use
• Open language, but closed development: new releases are still the responsibility of the three original authors
• Big community participation in the lua-l mailing list and the lua-users wiki
• A package manager, LuaRocks, and alternative Lua implementations: LuaJIT, JVM, .NET, JavaScript...
• Several frameworks for developing mobile games: Corona, Gideros, Codea, MOAI...
2.lua应用在哪里?
Lua学习系列(一)的更多相关文章
- Lua学习系列(二)
资源整理: 风云老师博客: http://blog.codingnow.com/eo/luaoeeeaeau/ 知乎: https://www.zhihu.com/question/20736660 ...
- Lua学习系列(五)
calling C functions from Lua 5.2 这篇文章也不错: http://blog.csdn.net/x356982611/article/details/26688287 h ...
- Lua学习系列(四)
lua 资源:http://www.dcc.ufrj.br/~fabiom/lua/ 第一个Lua程序 http://www.dcc.ufrj.br/~fabiom/lua/ 原文:https://w ...
- Lua学习系列(三)
Ubuntu14.04 上源码编译安装lua5.3 原文:http://blog.csdn.net/abclixu123/article/details/46676991
- 01LaTeX学习系列之---TeX的介绍与认识
目录 01TeX的介绍与认识 目录 前言 (一)TeX 的宣传 TeX - Beauty and Fun 1. TeX 是什么? 2. TeX 是哪家公司生产的? 3. 我们今天主角的名字怎么念啊?& ...
- 使用腾讯云 GPU 学习深度学习系列之二:Tensorflow 简明原理【转】
转自:https://www.qcloud.com/community/article/598765?fromSource=gwzcw.117333.117333.117333 这是<使用腾讯云 ...
- Lua学习高级篇
Lua学习高级篇 之前已经说了很多,我目前的观点还是那样,在嵌入式脚本中,Lua是最优秀.最高效的,如果您有不同的观点,欢迎指正并讨论,切勿吐槽.这个系列完全来自于<Programming in ...
- 分布式学习系列【dubbo入门实践】
分布式学习系列[dubbo入门实践] dubbo架构 组成部分:provider,consumer,registry,monitor: provider,consumer注册,订阅类似于消息队列的注册 ...
- Entity Framework Code First学习系列目录
Entity Framework Code First学习系列说明:开发环境为Visual Studio 2010 + Entity Framework 5.0+MS SQL Server 2012, ...
随机推荐
- CDONTS组件
在ASP中发送Email时往往需要一个COM组件支持,如果你没有第三方的Email组件,你可以使用IIS本身提供CDONTS EMail组件.这个组件使用时需要安装和启动SMTP服务.这个组件的名称为 ...
- 建立TCP连接的三次握手
请求端(通常称为客户)发送一个 SYN 报文段( SYN 为 1 )指明客户打算连接的服务器的端口,以及初始顺序号( ISN ).服务器发回包含服务器的初始顺序号( ISN )的 SYN 报文段( S ...
- C语言头文件
最近在工作当中遇到了一点小问题,关于C语言头文件的应用问题,主要还是关于全局变量的定义和声明问题.学习C语言已经有好几年了,工作使用也近半年了,但是对于这部分的东西的确还没有深入的思考过.概念上还是比 ...
- NSTimer内存方面的探究
今天研究一个框架,看到它对NSTimer的处理,感觉很有意思.于是自己在各种情况下都研究了一下,现总结如下. 我们用到NSTimer时,似乎习惯于会在dealloc方法中把它invalidate掉,但 ...
- php 后台权限例子 (mysql 数据表)
说明 超级管理员的权限最高 可以操作所有的功能 !!! 超级管理员给特定的用户分配对应的权限 下文注解: 用户表 关联 用户组表 每个用户组对应特定的功能权限 !! ...
- 视频 -> 帧 浅析
原创:转载请注明出处 关于帧率 首先以下几个概念必须弄清楚 1.一个帧就是一个画面 2.视频有无数个帧组成 3.表达时间的量 CMTime 的定义: typedef struct { CMTimeV ...
- linux内核移植到S5pv210
make s5pv210_defconfig 1.System Type ---> (0) S3C UART to use for low-level messages 2.Kernel ha ...
- 动画——animation(2)
日常中,我们使用的动画来源有两个方面—— 第一个,自己去定义. 通过@keyframes去定义即可,格式如下: @keyframe animatename{ 0%{ //这里面写初始的对象的css样式 ...
- 转:设置HtmlUnitDriver代理及处理用户验证有关问题
selenium2 提供了一种无ui模式的driver,即htmlunitdriver.特点运行比较快.其实htmlunitdriver 是对htmlunit 的封装,这样大家就可以使用自己习惯sel ...
- MongoDB如何设置权限(类似关系型数据库的用户名和密码)
MongoDB 缺省是没有设置鉴权的,业界大部分使用 MongoDB 的项目也没有设置访问权限.这就意味着只要知道 MongoDB 服务器的端口,任何能访问到这台服务器的人都可以查询和操作 Mongo ...