lua-users home
lua-l archive

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

Message: 2
Date: Tue, 22 May 2018 08:08:16 -0300
From: Roberto Ierusalimschy <>
Subject: Re: Circular #include between lstate.h and ltm.h
To: Lua mailing list <>
Message-ID: <">>
Content-Type: text/plain; charset=us-ascii

> I was directed here from github
> Deleting #include "lstate.h" from ltm.h looks like the right fix to me.

The problem in that link is stated like this:

  lstate.h uses TM_N from ltm.h and lstate.h uses nothing from ltm.h

Maybe I am missing something, but that statement seems slightly

-- Roberto

Hi Roberto,

Good point, well made. ltm.h uses nothing from lstate.h. 

What I actually did after seeing the circular include was delete one, notice the build break, then delete the other and see that the build & test was fine. Then actually check the contents of the headers and the order in which they're included in various files.