Comments (6)
I'll hold this open for now until I can make sure its fixed inside Hotpot too, have to review how we handle macro searching to make sure we are using the new code. I think it should be fine but it's been a few months. We run a bit of custom stuff to makes sure macro files are tracked as a dependency for cache invalidation which requires a one-line patch to fennel.lua to test.
from hotpot.nvim.
Interesting, I will do some more testing and open an issue on the Fennel repo.
Thanks for you help!
from hotpot.nvim.
I was looking to check another issue and I saw that this issue was still open. At the moment it has worked perfectly so I think this issue can be closed.
from hotpot.nvim.
That error is from Fennel directly, seems that it behaves the same outside of Hotpot.
--no-compiler-sandbox == compilerEnv = _G
and --globals "*" == allowedGlobals = false
from my interpretation of the docs.
~/pr/bu/hotpot-issue_48/co/fnl main ⚡
λ ./fennel --no-compiler-sandbox --globals "*" -c core/init.fnl
Compile error in core/init.fnl:7
Compile error in ./core/macro-utils.fnl:9
symbols may only be used at compile time
(= `fn (. x 1))
^^
* Try moving this to inside a macro if you need to manipulate symbols/lists.
* Try using square brackets instead of parens to construct a table.
stack traceback:
[C]: in function 'error'
./fennel:3363: in function 'fennel.friend.assert-compile'
./fennel:2211: in function 'fennel.compiler.assert'
./fennel:3209: in function 'fennel.compiler.do-quote'
(...tail calls...)
./fennel:2681: in function <./fennel:2680>
(...tail calls...)
./fennel:1697: in function <./fennel:1692>
(...tail calls...)
./fennel:2681: in function <./fennel:2680>
(...tail calls...)
./fennel:1573: in function <./fennel:1568>
(...tail calls...)
./fennel:2681: in function <./fennel:2680>
(...tail calls...)
./fennel:1573: in function <./fennel:1568>
(...tail calls...)
... (skipping 4 levels)
[C]: in function 'require'
./core/macro-module.fnl:1: in main chunk
(...tail calls...)
./fennel:2020: in field 'require-macros'
src/fennel/macros.fnl:288: in function <src/fennel/macros.fnl:283>
(...tail calls...)
[C]: in function 'xpcall'
./fennel:2657: in function 'fennel.compiler.macroexpand'
./fennel:2837: in function 'fennel.compiler.compile1'
./fennel:3068: in function 'fennel.compiler.compile-stream'
(...tail calls...)
[C]: in function 'xpcall'
./fennel:5660: in function <./fennel:5646>
(...tail calls...)
[C]: in ?
(import-macros {: if-fn-hello-else-bye} :core.macro-module)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
* Try moving this to inside a macro if you need to manipulate symbols/lists.
* Try using square brackets instead of parens to construct a table.
~/pr/bu/hotpot-issue_48/co/fnl main ⚡
λ
from hotpot.nvim.
Opened the following issue on the Fennel repository: bakpakin/Fennel#406
from hotpot.nvim.
bakpakin/Fennel#406 is fixed now 🎉
from hotpot.nvim.
Related Issues (20)
- `vim.loader` support HOT 1
- Diagnostics includes path before message
- Problems installing... hotpot.searcher.module not found when using lazy.nvim HOT 2
- Bump to fennel 1.3.1
- Problems for using api.make to build ~/.config/nvim/init.fnl HOT 5
- Broken on Windows because `vim.fs.normalize` converts all path separators to forward slash (`\` -> `/`) HOT 4
- lazy.nvim conflicts with fnl ftplugins HOT 5
- Diagnostics autocommand cant be deleted when a buffer is renamed
- Improve clearing Fennels `macro-loaded` table when needed. HOT 2
- Windows RUNNER~1 paths HOT 2
- Automatically load `plugin/*.fnl` files HOT 1
- attempt to call local 'glob_search' (a nil value) HOT 3
- "The hotpot.api.make usage has changed" on v0.9.7 HOT 4
- How to reduce startup time besides using `vim.loader.enable()`? HOT 2
- Diagnosing slow api.make.build() performance HOT 3
- `(include mod)` depends on CWD / fennel.path value HOT 1
- Error loading `init.fnl` looking in `.config/fnlm/fnl` instead of `.config/nvim/fnl` HOT 4
- Compiler environment for plugins HOT 2
- Using `folke/lazy.nvim` with module-name/string plugin definitions HOT 27
- `include` path behavior should match `require` behavior HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from hotpot.nvim.