Giter Club home page Giter Club logo

Comments (1)

ericoporto avatar ericoporto commented on August 30, 2024

OK, I started to play with this idea but it isn't as simple as I hoped...

  • Here's an example commit that gets rid of all ifdef stuff (I mostly deleted but commented a few things) ericoporto@813a186
  • Also here's simply allowing the preprocessor to keep the comments: 35e282c

Now for the issues...

It looks like there is some reliance on the character index in the original script, between the autocomplete and scintilla. Additionally, the define macros in the AutoComplete only holds the name of the macro and not their values too - say you would get all imported headers to get the defines from their autocomplete data to then add to the macro definitions of the preprocessor so you can run the preprocessor and the autocomplete on top of it... It won't be as simple.

There is also a GetLocalVariableDeclarationsFromScriptExtract which you want to get the preprocessor to run too (I think?) but I don't know how yet.

It seems that doing this requires having some way to translate back and forward the character position between the original script as in the scintilla document and an in-memory preprocessed version of it, but this will then add a new layer of bugs. I wonder if there is a way to instead of using character ref use just line number, which then could match between both the non-preprocessed and the preprocessed version.

from ags.

Related Issues (20)

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.