errors and warnings / manifest / W4304
W4304 warning
Flavors' load orders conflict; falling back to per-flavor TOC layout
- area
- manifest (x4xxx)
- fails the build
- with --deny-warnings
The flavors need their files in different orders: in one flavor a must load
before b, in another b before a (below, because an import depends on the
flavor). A single TOC lists the files once, in one order, so with
"toc-layout": "auto" wowlua falls back to one TOC per flavor, each in its
own order. The AddOn works; the warning says why its TOC layout changed.
To keep one TOC, remove the conflicting load-time dependencies. To accept one
TOC per flavor without the warning, set "toc-layout": "per-flavor".
Example
{ "package": { "name": "playground", "version": "0.1.0", "wowlua": "^0.13" }, "flavors": { "camelot": {}, "vanilla": {} }}import flavor from "wowlua:meta"@if(flavor == "camelot")import b from "./b"export local a = "a"print(a, flavor)import flavor from "wowlua:meta"@if(flavor == "vanilla")import a from "./a"export local b = "b"print(b, flavor){ "package": { "name": "playground", "version": "0.1.0", "wowlua": "^0.13" }, "flavors": { "camelot": {}, "vanilla": {} }, "build": { "toc-layout": "per-flavor" }}import flavor from "wowlua:meta"@if(flavor == "camelot")import b from "./b"export local a = "a"print(a, flavor)import flavor from "wowlua:meta"@if(flavor == "vanilla")import a from "./a"export local b = "b"print(b, flavor)The compiler reports it like this:
warning[W4304]: the flavors need different load orders; using per-flavor TOC files = in wowlua.json
Related codes
| code | message |
|---|---|
| E4301 | toc-layout: "single" forced, but a targeted client lacks a needed TOC feature |
Offline
$ wowlua explain W4304 W4304 (warning): Flavors' load orders conflict; falling back to per-flavor TOC layout