Git Product home page Git Product logo

rgbds-vscode's People

Contributors

donaldhays avatar jendrikw avatar sukus21 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

rgbds-vscode's Issues

Additional include folders don't seem to be working

Or maybe I'm doing something wrong?

Here's my project structure :

root  
   |- src (main.asm, memory.asm,)  
   |- include (hardware.inc)  
 build.bat  

in main.asm at the top I have :

include "include/hardware.inc"     
include "src/memory.asm"

And in my settings.json

  "rgbdsz80.includePath": [
        "src/",
        "include/"
    ]

My build.bat builds from the root, so all the files I include are included relative to the root, instead of the current file :

"../asm/rgbasm" -o tmp/temp.o src/main.asm
"../asm/rgblink" -o build.gb tmp/temp.o
"../asm/rgbfix" -v -p 0 build.gb

I couldn't get auto completion for included files working in this config. I tried multiple entries in rgbdsz80.includePath to no avail :

  • /src/
  • src/
  • ./src/
  • ${workspaceFolder}/src/
  • ../

Thank you!

Symbol scoping improvements

ISSOtm - Today at 11:21 PM
Although I don't mind symbols in a branch not appearing in others that much, the constants and macros branches are always included, and I really use these a lot.

My idea would be to construct a tree of the files included

Such that non-exported symbols in files declared before the current one in its parents (if any) are added to Intellisense

That was a long descriptor.

Dovuro - Today at 11:24 PM
Hmmm. I think that's reasonable.

So a.asm includes b.asm and then c.asm. And so we make it so that c.asm can see everything declared in b.asm, as well as any symbols declared in a.asm prior to the include statement of c.asm?(edited)

Not working for .asm file extension

I instaled the last version on VSCode and the extension stops being activated for .asm source files after I close/reopen the source folder. It works consistently with .sm83 extension, though.

Any ideas?

Comments starting with * are not recognized as comments

According to the man 5 rgbasm: 'anything that follows a "*" that is placed right at the start of a line is a comment'. rgbds does not currently support this kind of comments. That is an obscure feature of rgbds, maybe. But it shouldn't be too hard to implement .

Numbers with underscores not recognized

Syntax highlighting seems to break when introducing a _ separator into numeric literals.

This is valid RGBASM syntax and should probably be highlighted.

Not a huge issue, but probably an easy fix so I thought I'd mention this.

New version of hardware.inc doesn't work

The newest version of the gbdev maintained hardware.inc recently updated to use the RGBDS v0.5.0 DEF syntax. This seems to break this extension's ability to read the include file. Swapping back to a previous version of the hardware.inc file prior to this change makes it work again. However, to keep up to date I think it'd be good to support the currently maintained version.

Please let me know if you need any other information.

Support multiple instructions per line

https://rgbds.gbdev.io/docs/v0.7.0/rgbasm.5#SYNTAX

[label:] [instruction [:: instruction ...]] [; comment]

Multiple instructions on one line can be separated by double colons ‘::’.

ld a, [hli] :: LD H, [HL] :: Ld l, a

I'm worried about this one. The extension is mostly a random ad hoc mashup of regexes. I fear multiple instructions per line may break fundamental assumptions.

Though, when playing with the new syntax, it looks like the only immediately obviously wrong thing is that I don't get instruction completion hints after the first instruction? So maybe it won't be that bad?

Completions display formatting bug

Completions seem to have a formatting issue wherein the N flag is displayed on the same line as the Z flag. You can see this in the screenshot below.

image

VSCode version: 1.34.0 a622c65b2c713c890fcf4fbf07cf34049d5fe758 2019-05-15T21:49:51.528Z
Extension version: 2.4.0
Platform: MacOS 10.14.4

Capitalization rules affect within word boundaries

The extension's autocapitalization features incorrectly changes preprocessor directives that it finds within label names.

For example, if my language.keyword.preprocessor is set to "upper", then I cannot save a file with a routine called MemSet, because it incorrectly gets changed to MemSET. Only the label itself is changed (not where it is referenced), breaking labels since they are case-sensitive.

Support raw strings

https://rgbds.gbdev.io/docs/v0.7.0/rgbasm.5#String_expressions

Raw strings are prefixed by a hash ‘#’. Inside them, backslashes and braces are treated like regular characters, so they will not be expanded as macro arguments, interpolated symbols, or escape sequences. For example, the raw string #"\t\1{s}\" is equivalent to the regular string \\t\\1\{s}\\. (Note that this prevents raw strings from including the double quote character.) Raw strings also may be contained in triple quotes for them to be multi-line, so they can include literal newline or quote characters (although still not three quotes in a row).

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.