That's the style! :) - page 8

 
AlexEro >> :

Here's a one line asty.bat batter:


astyle.exe --indent=tab --indent=force-tab=3 --style=allman --delete-empty-lines --pad-oper --unpad-paren --pad-paren-out %1 %2 %3 %4 %5 %6 %7 %8 %9


and you're in luck.

http://astyle.sourceforge.net/astyle.html


And this is mine:


@astyle. exe -- mode= c -- style= allman -- indent= spaces=2 -- indent- switches --break- blocks --break- elseifs --delete- empty- lines -- pad- oper -- unpad- paren -- convert- tabs %1 %2 %3 %4 %5 %6 %7 %8 %9
 
Helex >> :

I think brackets should be highlighted. It's such a bad thing to pick them out with your eyes.

That's how handy it is in the studio:

it would save hundreds of man-hours of work to spot a trivial error. Especially since it's a no-brainer for the editor.

I agree. Now I have to upload to alternative editors like AlkelPad or Notepad++. The paired brackets are highlighted there.

Shit. These editors are free and act as an alternative to Windows Notepad. Couldn't MQ introduce this simple and useful feature in ME?

 
simpleton >> :


And this is mine:


You're just very young, and you have the time, energy and desire to bounce your cursor over invisible spaces, and constantly jump up and down in waves of lines. But grown-up, serious guys don't have time to do that.

 

Greetings!

Started poking around mq5.... today:( Joining..... Code design style is just awful.

 
DDFedor >> :

Well, it's not "spades", it's common sense reasoning and conclusions... The "spade" means "whatever", like you swear, take your breath away, and move on...

If sound reasoning had any effect on the MC, my post wouldn't be there. ;-). You'd think this is the first time we've spoken to them.

Neither mate nor personality has been crossed. Really just going all out.

 

I'll put in my five cents.

When I used to read statements about programming style, I thought it was about how the program was written.

Let me explain: the same idea can be expressed in the language of Pushkin, the CPSU Central Committee, Uncle Grisha, Zhvanetsky, etc.

That is the style.

And what is being discussed here is the peculiarities of design.


Storm in a glass of water.

 
hhohholl >> :

And what is being discussed here are design features.


Storm in a glass of water.

Maybe from a certain point of view, but my experience, for example, shows the opposite - good code (from algorithmic point of view, so to speak) is usually written in such a way, that you don't have to break your eyes and brains looking for what is relevant and why. However, considering the size of a typical MQL program... Really, a storm in a teacup. :)

 
hhohholl >> :

Let me explain: the same idea can be expressed in the language of Pushkin, the CPSU Central Committee, Uncle Grisha, Zhvanetsky, etc.

That's the style.

And what we are discussing here are peculiarities of design.

Just because a simple program text is enough for you (no matter how it's written) doesn't mean that others have the same minimal needs ;)

Tell me please, why the ESKD drawings standard is made as a standard? Well, take a piece of paper, draw a drawing with a felt-tip pen and show it to uncle Vasya so that he could carve a part for you. Yes, so that all people, "regardless of country of residence, religion and gender" equally understand the drawing they are looking at, and always know that the author's name can always be found in the lower right corner of the main inscription (rather than somewhere on the back of the sheet). And (no matter who the "author" is) the shading should mean one thing - the cut surface of the part (and not just decided to paint to look nicer).

Storm in a glass of water.

But the developers (already) do not think so. thanks to this "storm" they have thought about the fact that people are different and if you want to make a mass product - it must be made universal. now there are specific questions, what and how to configure in the styler, the work goes and "we will all be happy.

 
ForexTools >> Tell me please, why the USCD drawings standard is made as a standard? Take a piece of paper, draw a drawing with marker pen and show it to uncle Vasya so that he could carve a part for you. Yes, so that all people, "regardless of country of residence, religion and gender" equally understand the drawing they are looking at, and always know that the author's name can always be found in the lower right corner of the main inscription (rather than somewhere on the back of the sheet). And (no matter who the "author" is) the shading should mean one thing - the cut surface of the part (and not just decided to paint it to look nicer).
An interesting topic, by the way. I read on an Australian forum once that they have no unified standard on electronic and/or automation circuits (I think it was a while ago - not sure for sure).
 
Azzx >> :
An interesting topic, by the way. Once on one forum I met information from emigrants to Australia - they have just no unified standard on (I think it was a long time ago - I'm not sure exactly) electronic and/or automation circuits.

I don't know about Autralia, but on the subject of style settings, in PCAD, where (also quite a long time ago) I drew/plotted electric circuits, you could create/change any elements. True, it never occurred to me to designate, say, 2INE differently than it was scored there. But it was possible to draw it any way you wanted. Now there are international standards (ISO) where everything is strictly regulated.

By the way, there is an international standard group for C#, C++, etc. Doesn't it say anything about styles?

Reason: