Forum > Suggestions

A modest proposal in response to those who want "curly brackets"

<< < (4/8) > >>

PierceNg:

--- Quote from: Leledumbo on February 03, 2021, 08:02:17 pm ---
--- Quote from: ASBzone on February 01, 2021, 01:27:34 pm ---Or GoLang...

--- End quote ---
That one refuses to be called a C family member despite taking the basic block structure from it just because it's also inspired by Oberon (consequently, Pascal) for declaration sectioning, declaration order (identifier first, type later) and type bound procedures, perhaps also import aliasing.

--- End quote ---

The few times I used Go for little ~100 LOC CLI tools it felt like C with training wheels.

lainz:
I don't understand all the hate about other languages.

ASBzone:
My son (age 19) has dabbled in Pascal, but greatly prefers Python, which he took to in a heartbeat when he saw it.  I tease him about compiled speed all the time, and his fear of strongly typed languages, but he's integrated Numba and Numpy to get a lot of performance from his code.

This week he has convinced me that we should both learn an extra language, and he chose Nim.  I was going to pick GoLang, but he thinks it will be cool to do the same language.  I'm going to take him up on that, and we'll have a little bit of fun porting some of our existing apps (at least smaller ones) into Nim.  He likes it because it is quite Python like, and I appreciate that it has robust typing.

Personally, while I can understand why people often ask for X feature in some other language, I am okay with each language having its focus and strong points and differences.  I cannot imagine any language having all the features that *I* like in a language, yet managing to remain appealing to everyone else.  I also expect that the resulting complexity from such a language or UI would be very undesirable.

Off to a little bit of Nim development I go...  :D

Martin_fr:
Think of Pascal as your dentist. And then you know why curly braces wont fit.

PascalDragon:

--- Quote from: skalogryz on February 03, 2021, 09:32:20 pm ---To be honest, I don't see a reason why not to have some sort of "Cascal" project.
--- End quote ---

But it's not something the FPC compiler will dabble in.


--- Quote from: skalogryz on February 03, 2021, 10:48:03 pm ---(yes, people will complain that copy-pasted C code doesn't compile in Cascal)

--- End quote ---

Which is the reason why someone added support for << and >> in FPC which is still driving me nuts regarding future nested specialization support especially as it's done inside the scanner... %)


--- Quote from: dpremus on February 03, 2021, 11:54:09 pm ---So in that time I was used  "(*"   and  "*)" instead curly brackets. and "(." ".)" instead "["  "]"
But  "(*"   "*)" are still great for debugging, for example when you need to comment some code that already have comments with curly brackets.
--- End quote ---

Fun fact: FPC handles the replacement for square brackets as well (and obviously the comment style):


--- Code: Pascal  [+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i < x.length; i++) { x[i].style.maxHeight='none'; x[i].style.height = Math.min(x[i].clientHeight+15,306)+'px'; x[i].style.resize = "vertical";}};} ---{$mode iso} var  a: array(.0..4.) of LongInt;begin  (* mixing is okay for square brackets as well, but to do this for comments you need to     use mode ISO and FPC 3.3.1! }  a(.4.) := 42;  a(.3] := 2;  a[2.) := 1;end.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version