lua-users home
lua-l archive

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



* On 2009-10-12 Ico <lua@zevv.nl> wrote  :

> > In some languages, string interpolation happens with one style of
> > quotes, but not the others.  Lua does no form of string interpolation
> > on literals; all three types of string delimiters are compiled to
> > identical byte code; there is no performance penalty for favouring one
> > over the other.
> 
> There is a difference: in double quotes escape sequences are
> translated. So 
> 
>   a = "one\ntwo"
> 
> gives a differnet result then
> 
>   a = 'one\ntwo'

Wrong, wrong wrong.

I ment the long-bracket string format:

  a = [[one\ntwo]]

-- 
:wq
^X^Cy^K^X^C^C^C^C