GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Port performance improvements to Neovim/Lua · Issue #32 · clojure-vim/clojure.vim

Port performance improvements to Neovim/Lua #32

New issue
Copy link
New issue
Copy link
Open
Open
Port performance improvements to Neovim/Lua#32
Copy link
Labels
indentationAffects indentationAffects indentationperformanceAffects performanceAffects performance
Milestone
Indentation overhaul

Description

@NoahTheDuke
NoahTheDuke
opened on May 2, 2023
Issue body actions

Regarding Neovim, until Vim9 script support is added, the "New (legacy)" code will be used. If anyone would like to volunteer to write a Lua implementation of this code for Neovim please open an issue and we can discuss how to integrate it.

Originally posted by @axvr in #31 (comment)

I'd be willing to try my hand at it.

Reacted by Alex Vear

Activity

  1. dkarvik commented on May 2, 2023

    @dkarvik
    dkarvik
    on May 2, 2023
    Member
    More actions

    Fwiw, I believe the neovim team wrote a Vim9->Lua transpiler to handle this for all the Vim9 code in core.

    Reacted by Alex Vear
  2. axvr commented on May 3, 2023

    @axvr
    axvr
    on May 3, 2023
    Member
    More actions

    @SevereOverfl0w, this? https://github.com/tjdevries/vim9jit

    Interesting approach they've taken... It looks like they manually run that tool over Vim9 code which generates a Lua version and a Vim script stub for it. (As seen here: https://github.com/neovim/neovim/pull/21623/files)

    ("Interesting" in a bad way, as it seems it would make tracking and integrating upstream changes more challenging and doesn't work for plugins either.)

  3. axvr commented on May 6, 2023

    @axvr
    axvr
    on May 6, 2023
    Member
    More actions

    The main question on my mind currently is how to have 3 versions of the same code nicely integrated, to make maintenance easy but ensure that the following scenarios are met:

    1. Use the new legacy Vimscript code if using this repo as a plugin on Vim 8.2 and below.
    2. Use Vim9 script version when included in Vim.
    3. Use Vim9 script version when this repos is used as a plugin on Vim 9+.
    4. Use a Lua version of the code when this library is used as a plugin on Neovim.
    5. Use a Lua version when included* in Neovim?

    * I'm unsure how to get an optimised Lua version into Neovim. Previously I have only had to create a PR with Vim and a few days later, the Neovim team pick up the changes and copy them to their fork. So if a Vim9 version was included in Vim, would they compile that to Lua using Vim9jit?

    Another unknown is the performance difference of a Vim9->Lua version, compiled with Vim9jit, vs. a hand-rolled Lua version. (The hand-rolled verison would definitely be more readable, but requires additional maintenance.)

  4. axvr
    added
    indentationAffects indentationAffects indentation
    performanceAffects performanceAffects performance
    on Jun 23, 2023
  5. axvr
    added this to the Indentation overhaul milestone on Jun 23, 2023
  6. gpanders commented on Jun 23, 2023

    @gpanders
    gpanders
    on Jun 23, 2023
    More actions

    I'm unsure how to get an optimised Lua version into Neovim. Previously I have only had to create a PR with Vim and a few days later, the Neovim team pick up the changes and copy them to their fork. So if a Vim9 version was included in Vim, would they compile that to Lua using Vim9jit?

    For now at least, the most likely answer is that if the ftplugin/indent files are converted to Vim9 upstream, they would simply not be ported to Neovim and we would continue to use the "legacy" version. This is obviously not ideal, but we have not yet started using the vim9jit tool in any systematic way (it's been used experimentally a few times, but that's it).

    We are not (yet) accepting Neovim-specific implementations of ftplugins/indent files. Primarily because it has not been necessary, and tracking upstream both (1) benefits both projects and (2) minimizes maintenance burden. If filetype plugins (particularly those that are upstreamed to Vim) start moving to Vim9 then we will likely need to figure out a long term solution.

    Reacted by Justin M. Keyes, Sean Dewar and Noa Bogart
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    indentationAffects indentationAffects indentationperformanceAffects performanceAffects performance

    Type

    No type

    Projects

    No projects

      Milestone

      • Indentation overhaulNo due date

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402520 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.