Code Monkey home page Code Monkey logo

asm-lsp's Introduction

Language Server for GAS/GO Assembly

crates.io Tests

Goal

Provide hovering, autocompletion, signature help, go to definition, and view references for assembly files written in the GAS/NASM or GO assembly flavors. It supports assembly files for the x86 or x86_64 instruction sets.

This tool can serve as reference when reading the assembly output of a program. This way you can query what each command exactly does and deliberate about whether the compiler is producing the desired output or whether you have to tweak your code for optimisation.

Installation

Using cargo

Install using the cargo package manager, either from crates.io or from github:

cargo install asm-lsp
# or to get the latest version from github
cargo install --git https://github.com/bergercookie/asm-lsp

Set up as a language server

Add a section like the following in your settings.json file:

"asm-lsp": {
    "command": "asm-lsp",
    "filetypes": [
        "asm", "s", "S"
    ]
}

[OPTIONAL] Configure via .asm-lsp.toml

Add a .asm-lsp.toml file like the following to your project's root directory and/or ~/.config/asm-lsp/ (project configs will override global configs) to selectively target specific assemblers and/or instruction sets.

version = "0.1"

[assemblers]
gas = true
go = false

[instruction_sets]
x86 = false
x86_64 = true

Demos / Features Documentation

Hovering / Documentation support

Autocomplete

Goto Definition

View References

Signature Help

  • Triggering signature help is dependent on your editor and LSP client.
    • Using Neovim's built in LSP client, this can be done via the command :lua vim.lsp.buf.signature_help().
    • Using coc, this issue comment suggests the remap inoremap <silent> ,s <C-r>=CocActionAsync('showSignatureHelp')<CR> to trigger signature help in insert mode.

Acknowledgements

Current rust package builds on top of the opcodes python package

asm-lsp's People

Contributors

maratyszcza avatar willlillis avatar bergercookie avatar decodetalkers avatar notashelf avatar promyloph avatar pwaller avatar c-cube avatar enriquefft avatar mquigley avatar

Forkers

gilbertfrancois

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.