News for hackers. Stuff that matters.
Re:Object-Oriented Programming in Oberon-2 [pdf] by abricq on Monday November 20, 2023 @03:08PM (#38353829)
I happen to work in Oberon pretty much every week. At my company, we program OS for mobile robots and have been carrying Oberon code since 25 years. The code base is huge, and it works really well. It’s been under production for all these years and we know it’s robust. It’s definitely not fast, but most applications don’t require the speed offered by modern languages. That’s why it was never translated in C++ or Rust or any « better languages ».

In my daily practice, I find the following limitations to be the most challenging ones.

* No generic type : that’s extremely limiting, especially when implementing math libraries.

* The garbage collector (using the XO2 real-time OS) does not collect array of primitive types, only array of pointers are collected. Honnestly it would be much easier to not have the garbage collector.

* extremely small standard library (but this is to be expected for a niche language …).

* the only tooling that you have is the tooling that you build yourself (editor, completion, debuting, etc …)

I often wonder how many other people work in Oberon. I’d love to share with someone else than me that does !

Re:Object-Oriented Programming in Oberon-2 [pdf] by eterps on Monday November 20, 2023 @03:12PM (#38353923)
That's impressive! Are there still any advantages in using Oberon commercially in 2023? (I use it mainly for study)
Re:Object-Oriented Programming in Oberon-2 [pdf] by abricq on Monday November 20, 2023 @03:17PM (#38354013)
I don’t think there is any advantage to start a new code base in Oberon. The language itself is just like any OOP language, with very pronounced limitations. Typically, you’ll often have to fix problems with the compiler, or with the OS.

I guess that sometimes the risk to make a language migration (and to introduce some bugs) is higher than the performance benefits.

Re:Object-Oriented Programming in Oberon-2 [pdf] by eterps on Monday November 20, 2023 @03:20PM (#38354049)
Which Oberon compiler do you use?
Re:Object-Oriented Programming in Oberon-2 [pdf] by ralphc on Monday November 20, 2023 @08:58PM (#38357891)
Do you work in other languages in your spare time?

Do you feel left behind working in a mainly OOP language when the industry seems to be heading towards functional programming?

Re:Object-Oriented Programming in Oberon-2 [pdf] by krylon on Monday November 20, 2023 @03:14PM (#38353952)
Fascinating! I was skimming through TFA, wondering if anyone actually uses Oberon for real. TIL: Yes, they do.
Re:Object-Oriented Programming in Oberon-2 [pdf] by pjmlp on Monday November 20, 2023 @03:21PM (#38354073)
Astrobe is still in business, selling Oberon-07 compilers.
Re:Object-Oriented Programming in Oberon-2 [pdf] by pjmlp on Monday November 20, 2023 @03:28PM (#38354172)
As I mentioned in another comment, it was very interesting experience for what we had back then, as a full single user graphical workstation OS.

Outside of its original environment, isn't quite the same.

Thanks for sharing your experience.

Re:Object-Oriented Programming in Oberon-2 [pdf] by Koshkin on Monday November 20, 2023 @05:20PM (#38355725)
> No generic type

A good macroprocessor can provide a similar capability (and much more). My favorite example is to simply use an ASP-like syntax, where you could have the same language as your macro language, along with the "code inversion" brackets ("<%" in the case of ASP).

Re:Object-Oriented Programming in Oberon-2 [pdf] by imglorp on Monday November 20, 2023 @08:42PM (#38357717)
Please no. That's how CFront worked in the late 80s: one of the first c++ compilers that emitted c for classes and generics. It was slow, clumsy, and errors completely opaque. It served to get c++ implemented quickly during its early years, but things got much better when real compilers came out.

Hygienic macros integrated with a language, ok. But don't implement the language in a macroprocessor.

Re:Object-Oriented Programming in Oberon-2 [pdf] by Rochus on Monday November 20, 2023 @06:39PM (#38356610)
Did you already have a look at http://oberon-lang.ch? It's a new version of Oberon, compatible with Oberon-2 and Oberon 90, with support for generic modules. It also has an IDE with syntax colouring, semantic navigation, cross-referencing and source-level debugging. Performance is close to C++ (https://github.com/rochus-keller/Oberon/blob/master/testcase...).
Re:Object-Oriented Programming in Oberon-2 [pdf] by ivan_denisov on Thursday November 23, 2023 @05:36AM (#38391357)
I am also working in Oberon, We are developing devices using compiler O7 for STM32 and also may years developing desktop applications with BlackBox Component Builder (also version of Oberon language).
Re:Object-Oriented Programming in Oberon-2 [pdf] by WojtekSkulski on Sunday November 26, 2023 @10:45PM (#38427802)
I used Component Pascal under Black Box Component Builder for developing scientific image processing and adaptive optics. The math libraries by Robert Campbell are available from Component Pascal Collection. The name of Robert's package collection is unassuming word Chill. It is the most amazing set of math, algebra, graphics, and utilities. All written in Component Pascal which can be backported to Oberon-2. You can download BlackBox from the same page. http://www.zinnamturm.eu/index.htm