1. 26
  1. 13

    One of my hugest pet peeves with programming language main pages is when they describe their syntax, but have absolutely no code examples on their landing page or within 1 or 2 clicks. I’ve been clicking around on their website and haven’t found any obvious link to a short example of what the language looks like.

    1. 9

      Being one of the authors I admit: yes we should improve this.

      Find code examples in presentations and in the latests article referred to in the Blog section: https://www.blech-lang.org/blog/

      1. 2

        Even starting from that link to the blog, finding a code sample takes quite some time, so here’s a direct link to the first Blech code sample in the latest blog post: Decoding the DCF77 Signal with Blech > The Application’s Top-Level.

        And here’s a short code sample from later in that same post:

        activity CaptureSync (dcf77: bool)
            // Perform the measurement and restart if the level drops meanwhile.
            when not dcf77 reset
                var len: nat16 = 0
                repeat
                    await true // Await next sys tick.
                    len = len + 1
                until len > DCF77_SYNC_LEN end
            end
        end
        
    2. 8

      There’s a name that doesn’t work in English, as blech tends to be used as an expression of disgust.

      1. 12

        expression of disgust.

        Given some of the things I’ve heard about the trials and tribulations of embedded programming this may not be unfair.

        1. 3

          Given some of the things I’ve heard about the trials and tribulations of embedded programming this may not be unfair.

          Having done embedded development long in the past, it’s certainly apt!

        2. 9

          I was expecting a novelty language :)

          1. 2

            Same here! It the name made me think it was an esolang initially.

            1. 1

              Yeah, I expected this to be a parody language that does the opposite of what good languages do, resulting in something like INTERCAL. I think the name “Blech” will significantly slow the growth of the language.

            2. 7

              Seems to be done by Bosch Research, a German company. If it works for them … I see nothing wrong with it.

              1. 2

                Sure, but it might limit how seriously people take it. Then again, considering the silly names some projects have…

              2. 6

                Being one of the authors - we are aware of this. Blech should remind you of “bare metal”. Programs can run directly on “the Blech”. We also considered the name “Metal” but it was already taken by Apple.

                1. 2

                  I really appreciate you chiming in.

                  To me a die looks like a piece of blech.
                  Thus the name totally makes sense.

                2. 4

                  As German, I find the name very amusing. It’s usually used in disrespect towards sheet metal of questionable thickness/stability, something that bends easily and not being something that you want to relying on for bearing load. It’s sometimes used in an affectionate way, like the Trabbi being referred to as a ‘Blechle’ or ‘small Blech’. Anyways, in all uses I’ve heard it’s always been towards thin sheet metal.

                  1. 1

                    I checked several dictionaries but couldn’t find any evidence of this. Is it a local slang?

                    1. 2

                      I’m familiar with it, I don’t believe it’s local.

                        1. 1

                          Thanks. I wrote it with a (capital) ‘B’ and landed here:

                          https://en.wiktionary.org/wiki/Blech

                          1. 1

                            Yuck, case sensitive URL!

                      1. 2

                        I checked several dictionaries but couldn’t find any evidence of this. Is it a local slang?

                        Nope, not slang: https://www.merriam-webster.com/dictionary/blech

                        That was the first hit when I did a search.

                      2. 1

                        I also assumed it was named along the lines of Worst: http://worst.mitten.party/

                      3. 6

                        Cool to see synchronous programming explored again! To my knowledge the other main languages were Esterel, Lustre, and Eve. First two are incredibly niche and the last is now defunct.

                        1. 6

                          This article confirms Blech is influenced by Esterel, Lustre, and others:

                          https://www.blech-lang.org/docs/examples/virtuallock/Blech_Tutorial_BoCSE2019.pdf

                          1. 1

                            Others synchronous languages are ReactiveML (http://rml.lri.fr/), Céu (http://ceu-lang.org/), and HipHop.js (http://hop.inria.fr/home/hiphop/index.html). Céu is closest to Blech in intent.

                          2. 4

                            I’d be super interested to read a summary, but…

                            Reactive embedded realtime programming

                            A general introduction, design criteria and choices, … (todo)

                            https://www.blech-lang.org/docs/user-manual/#reactive-embedded-realtime-programming

                            It makes me rather sad that quite some time was obviously spent with their website, documenting minutia like syntax and the docs system, but the core statement of the language was not penciled down.