top | item 34287815

(no title)

vulcanash999 | 3 years ago

> I’ve skimmed over the code and it was processing hardcoded index positions. I repeat the person who did that had no concept of a loop. Since the query was returning more than 250 results the remaining rows were being ignored.

Unrelated, but this reminds me of a time when I had to write some code in some proprietery programming language in some industrial automation project to program a PLC. The language was similar to Visual Basic but lacked support for basic things such as for loops. I spent some time creating a "meta-language" that would compile code down to this language with added support for loops and some other stuff. Then I would paste the compiled code in the proprietary software each time I had to change anything.

discuss

order

Bouncingsoul1|3 years ago

That's odd most of these PLC are programmable with IEC 61131-3 languages,e.g. Structured Text which has For-loops. That said i did my fair share of metaprogramming as these usually lack dynamic allocation.

electroly|3 years ago

Most PLCs these days support 1131! My whole career in industrial automation was on older PLCs that were produced before 1131 existed. (And long before they added the "6"!) Lots of them are still running factories today. Not one of them supported anything like a for loop. The only loop is the whole program scan loop.