rfsmTools icon indicating copy to clipboard operation
rfsmTools copied to clipboard

Runtime errors with Lua 5.3

Open drdanz opened this issue 6 years ago • 3 comments

Steps to reproduce:

  • Create a new state machine
  • Add 2 nodes and a transition
  • Save
Cannot load /<path>/test.lua

Screenshot_20191220_104004

File generated

--
-- Authors: user
-- Version: 1.0.0
-- Created using rFSMGui
--
return rfsm.state {


    --States

    initial = rfsm.conn{ },

    --State_0
    State_0 = rfsm.state{
        doo = function()   end,

    }, --end of State_0


    --State_2
    State_2 = rfsm.state{
        doo = function()   end,

    }, --end of State_2



    --Transitions
    rfsm.trans{ src = 'initial', tgt = 'State_0', pn = 0 },
    rfsm.trans{ src = 'State_0', tgt = 'State_2', pn = 0 },
}

drdanz avatar Dec 20 '19 10:12 drdanz

With lua 5.1 everything works as expected

drdanz avatar Dec 20 '19 10:12 drdanz

Actually with lua 5.2 this state machine was different, the actual problem was that i renamed one of the nodes goto, which is a keyword in lua 5.2. With 5.3 this state machine still fails

drdanz avatar Dec 20 '19 10:12 drdanz

The incompatibility with lua5.3 is a known issue, not sure if it is our problem or rfsm.lua problem

Nicogene avatar Dec 20 '19 10:12 Nicogene