Git Product home page Git Product logo

Comments (5)

jeremiah-c-leary avatar jeremiah-c-leary commented on July 22, 2024

Evening @tossegus ,

I would agree there is no rule to enforce the behavior you are looking for. The rule instantiation_005 is close, but it will always want to put port map on it's own line. I am guessing you would want port map to be moved to it's own line if it was on the same line as the instance declaration?

Violation

  U_FIFO : FIFO port map (

  U_FIFO : FIFO
     generic map (
     )
     port map (

Fix

  U_FIFO : FIFO
     port map (

  U_FIFO : FIFO
     generic map (
     ) port map (

If so I could add to configuration options with the following defaults:

rules:
   instantiation_005:
       after__instantiation:  "new line"
       after_generic_map: "new line"

This would match the current behavior. Then for your formatting the configuration would be:

rules:
   instantiation_005:
       after_instantiation:  "new line"
       after_generic_map: "no new line"

Would that update give you the desired formatting?

--Jeremy

from vhdl-style-guide.

tossegus avatar tossegus commented on July 22, 2024

Evening @tossegus ,

I would agree there is no rule to enforce the behavior you are looking for. The rule instantiation_005 is close, but it will always want to put port map on it's own line. I am guessing you would want port map to be moved to it's own line if it was on the same line as the instance declaration?

Violation

  U_FIFO : FIFO port map (

  U_FIFO : FIFO
     generic map (
     )
     port map (

Fix

  U_FIFO : FIFO
     port map (

  U_FIFO : FIFO
     generic map (
     ) port map (

If so I could add to configuration options with the following defaults:

rules:
   instantiation_005:
       after__instantiation:  "new line"
       after_generic_map: "new line"

This would match the current behavior. Then for your formatting the configuration would be:

rules:
   instantiation_005:
       after_instantiation:  "new line"
       after_generic_map: "no new line"

Would that update give you the desired formatting?

--Jeremy

Hi!

Yes, that would give me the wanted formatting. 🙂

/ Tossegus

from vhdl-style-guide.

jeremiah-c-leary avatar jeremiah-c-leary commented on July 22, 2024

Morning @tossegus ,

I pushed an update for this to the issue-1176 branch. There are two new configuration options that will allow you to add or remove carriage returns depending on what comes before the port map aspect. When you get a chance, could you check it out on your end and let me know if it works for you?

Thanks,

--Jeremy

from vhdl-style-guide.

tossegus avatar tossegus commented on July 22, 2024

Good morning!

It looks like it works on my side! 🙂

/ tossegus

from vhdl-style-guide.

jeremiah-c-leary avatar jeremiah-c-leary commented on July 22, 2024

Awesome,

I will get this merged to master.

--Jeremy

from vhdl-style-guide.

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.