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, ...
随机推荐
- .Net日期处理之格式化
一.默认格式 2015/9/3 9:04:31 二.格式2 2015年9月3日 9:28:51 三.格式3 2015年9月3日 9:31 四.格式4 2015/9/3 9:39:01 五.格式5 20 ...
- ActiveMQ-CPP编译
1.activemq-cpp下载地址: http://activemq.apache.org/cms/download.html 2.相关依赖库 http://mirrors.hust.edu.cn/ ...
- 2.1 实践篇:使用ping来检测网速
1. Windows功能键+R ,打开cmd窗口 2. ping -n 200 www.baidu.com #ping网站www.baidu.com ,连续200次.验证连接. 可以ctrl+C 强制 ...
- 设置UITabBarController上ImageInsets后点击不断缩小
最近遇到了这样一个情况,客户要求做出这种效果的UITabBarController. 通过各种查询,得出UITabBarController有这样一个属性,是设置它的图片距上下左右距离的属性: nav ...
- java解析XML获取城市代码
运行前先导入dom4j架包,由于我们公司用的代理服务器所以下面我设置了代理ip,不需要的可直接忽略 package com.chengshidaima.tools; import java.io.Bu ...
- WPF从我炫系列4---装饰控件的用法
这一节的讲解中,我将为大家介绍WPF装饰控件的用法,主要为大家讲解一下几个控件的用法. ScrollViewer滚动条控件 Border边框控件 ViewBox自由缩放控件 1. ScrollView ...
- Trie/最短的名字
题目链接 /* 简单trie树的应用,注意在初始化的时候要把cnt也初始化,不然,WA! 下面的四分代码各有特点 */ //数组型,名字查询. #include<cstdio> #incl ...
- UITableView使用中的一些刁专问题总结
tableview中cell的系统分隔线问题(分隔线顶满或者缩短) //tableview代理方法,设置系统cell的分隔线 -(void)tableView:(UITableView *)table ...
- nand驱动移植
首先下载nand flash驱动 s3c_nand.c ,此文件包含着nand flash驱动具体的实现,将其复制到drivers/mtd/nand下: s3c_nand.c 下载地址 s3c_nan ...
- Android接收wifi路由器发送过来的一组字节数据
1.字节数组转换为字符串 byte[] byBuffer = new byte[20];... ...String strRead = new String(byBuffer);strRead = S ...