Re: [go-nuts] Hi - "Go versus Lazarus"

1,343 views
Skip to first unread message

Yves Junqueira

unread,
Mar 20, 2013, 3:52:40 PM3/20/13
to John Drummond, golang-nuts

Hey John, I think you should totally use Go. :-)

On Mar 20, 2013 8:21 PM, "John Drummond" <busf...@gmail.com> wrote:
Ok I am going to risk all by asking a noob question to this group.

I am looking at a project where I need speed and the ability to query a database and do some text processing and file writing, and be cross platform.

I was getting great results with Go but then I stopped and thought, well maybe Lazarus.  I don't need any UI its just command line interface I need, so Go fits the bill, but then again Free Pascal is higher in the popularity charts wher Go seems to be falling ((:)

Would appreciate any views.  Cheers.


--
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Ugorji Nwoke

unread,
Mar 20, 2013, 4:11:51 PM3/20/13
to golan...@googlegroups.com
Free Pascal is higher in the popularity charts wher Go seems to be falling ((:)

Where did u get that from? 

I looked at GitHub, and can't even see Free Pascal anywhere there, but see Go is there at #24 on most popular languages at github.

Nate Finch

unread,
Mar 20, 2013, 4:26:50 PM3/20/13
to golan...@googlegroups.com
It's also called Delphi - http://en.wikipedia.org/wiki/Object_Pascal

Delphi is #39 on github - https://github.com/languages/Delphi. Somewhat more popular by other metrics - http://www.tiobe.com/index.php/content/paperinfo/tpci/index.html

Go is modern, and has a ton of advantages over Delphi. It is also an up and coming language that is destined for greatness. So instead of using a language that is dying, like Delphi, you're on the leading edge.

Also, I would stab myself in the eye before using Delphi over Go.

-Nate

Nate Finch

unread,
Mar 20, 2013, 4:29:36 PM3/20/13
to golan...@googlegroups.com
I mean, really.... this has to be a troll.


program ObjectPascalExample;
 
type
  THelloWorld = class
    procedure Put;
  end;
 
procedure THelloWorld.Put;
begin
  Writeln('Hello, World!');
end;
 
var
  HelloWorld: THelloWorld;    
 
begin
  HelloWorld := THelloWorld.Create;  
  HelloWorld.Put;
  HelloWorld.Free;   
end.

egon

unread,
Mar 20, 2013, 6:46:20 PM3/20/13
to golan...@googlegroups.com
I write Delphi daily, and do things with Go and JS on the side. Here's my current suggestion -- use Lazarus for things where you need fast native UI... JS + HTML + Go where UI speed isn't that important, and Go for everything else. There aren't very nice DB APIs for Go... then again, it's only a little bit better in Lazarus/Pascal/Delphi.

Give some time and my suggestion will probably change to -- just use Go.

David Anderson

unread,
Mar 20, 2013, 6:47:50 PM3/20/13
to egon, golang-nuts
Depending how fast the UI needs to be, I've found Go + AngularJS to be a winning combination for responsive asynchronous UIs.

- Dave


David Leimbach

unread,
Mar 22, 2013, 11:10:46 AM3/22/13
to golan...@googlegroups.com
Lazarus/FreePascal has neat stuff like range types.  :-)

And it does NOT have to be a troll at all.  Oberon is a damned fine system and a Pascal derivative.

Dave

David Leimbach

unread,
Mar 22, 2013, 11:12:17 AM3/22/13
to golan...@googlegroups.com, egon


On Wednesday, March 20, 2013 3:47:50 PM UTC-7, David Anderson wrote:
Depending how fast the UI needs to be, I've found Go + AngularJS to be a winning combination for responsive asynchronous UIs.

Do you have any examples you can point us to?  This sounds compelling!

I've done nothing with AngularJS because I've done my very best to never write any Javascript.  I've tried Ada, COBOL and other languages, but Javascript just makes me feel ill for some reason.  I even like prototype based languages like Io, but not Javascript!!!  I don't know why!

Dave

Nate Finch

unread,
Mar 22, 2013, 11:46:08 AM3/22/13
to golan...@googlegroups.com, egon
I highly highly recommend reading Javascript: The Good Parts. It really won me over to the side of "Javascript: eh, not so bad".... which is good, since I was coming from the side of "Oh my god, why would you ever program in this horrible language?"  :)

AngularJS is a great frontend framework that I'm just starting to use... another Google project that seems to be bucking the latest trends and doing things in new, better ways.

David Anderson

unread,
Mar 22, 2013, 1:01:37 PM3/22/13
to David Leimbach, golang-nuts, egon
On Fri, Mar 22, 2013 at 8:12 AM, David Leimbach <lei...@gmail.com> wrote:


On Wednesday, March 20, 2013 3:47:50 PM UTC-7, David Anderson wrote:
Depending how fast the UI needs to be, I've found Go + AngularJS to be a winning combination for responsive asynchronous UIs.

Do you have any examples you can point us to?  This sounds compelling!

I can't promise that it's a good example, but this is the site/app I've been building with Go/AngularJS: http://kspcareerguide.appspot.com/ . If you don't know the game it refers to (Kerbal Space Program - also highly recommended, and it's on Steam Early Access!), it may be a little confusing, but the general idea is that it lets you navigate a mission DAG. The Go app mostly just serves the JSON mission DAG to the Angular app at this point, I'm still working on the more complex server-side logic.

I don't have public source code for it just yet, but I'll get it online tonight if you're interested. I'll not that it's probably not the best intro to angular, since I've started using more advanced features like partial views and request routing. For a more gentle intro, I strongly recomment http://egghead.io/ . It does a great job of hooking you, and explaining the more confusing (to a newbie) corners of angular.

Angular doesn't rid you of the need to write javascript, but what it does do is make the DOM, arguably the worst part of in-browser JS, completely invisible. Your javascript manipulates a data model, and angular takes care of binding that into your view. The rest of ECMAScript5 is not that bad, if you're a little careful.

My current analogy is that where regular JS with toolkits like jquery is like drawing GUIs by painting the pixels onto the screen, Angular is like using Qt Designer, or Visual Studio's GUI building stuff. It takes all the tedium out of it.

I can't guarantee that it'll cure your javascript allergy, but it cured mine, so who knows :).

- Dave

John Drummond

unread,
Mar 22, 2013, 7:17:17 PM3/22/13
to golan...@googlegroups.com
Thanks for the advice guys.  It WAS a serious question. 

For code thats cross platform and reasonably fast it seems to me its Go,  Lazarus, C++, or possibly Python or Java.  I was totally sold on Go but Lazarus is a new one on me and it did seem to just work and has RAD although I'm not really after a GUI.  I really appreciate your views - honestly!  

I think that once I get my head clear of some horrible C++ thats killing me I will continue the project in Go, I just hope that the Postgres driver carries on working OK.

I'm surely not the only one that gets mired in the question of what language to use for a project.....

all the best

Nate Finch

unread,
Mar 22, 2013, 11:23:58 PM3/22/13
to John Drummond, golan...@googlegroups.com

Sorry,  I didn't really mean I thought you were a troll. The Delphi code just does not look appetizing :)

Go is a great language,  I really think it has a huge future, and you'll like it more the more you use it.

--

Andrew

unread,
Mar 23, 2013, 12:10:57 AM3/23/13
to golan...@googlegroups.com
I was (un) fortunate to learn Borland Pascal some scary years ago as the second (after ASM286) language. And since then my attempts to learn C++ were an absolute disaster.
I spent some 5 years programming in ObjPas and later in Delphi{1-3} and i enjoyed it.
At the time (Delphi3) it was a very elegant language with clear syntax and absolutely great UI....
Last year , out of curiosity, i downloaded latest Delphi ( from unpronounceable company that owns it now) and was unpleasantly surprised with how the syntax looks now. To my unprofessional eye - bloated java like.
I did look @ Lasarus and syntax wise it looked SO much better.
So if i had to write something ( with your conditions in mind)  without need of GUI - i would try to use go, with gui - lasarus.

Paulo Pinto

unread,
Mar 23, 2013, 6:37:20 AM3/23/13
to golang-nuts
Funny, actually I think I would pick Delphi over Go given all the nice
features the language offers.

On Mar 20, 9:26 pm, Nate Finch <nate.fi...@gmail.com> wrote:
> It's also called Delphi -http://en.wikipedia.org/wiki/Object_Pascal
>
> Delphi is #39 on github -https://github.com/languages/Delphi. Somewhat
> more popular by other metrics
> -http://www.tiobe.com/index.php/content/paperinfo/tpci/index.html

Paulo Pinto

unread,
Mar 23, 2013, 6:39:40 AM3/23/13
to golang-nuts
Oberon and its sucessors Component Pascal, Oberon-2 and Active Oberon
are
quite interesting languages.

And also show how to write desktop operating systems in GC enabled
system programming
languages with acceptable performance.

Sadly only ETHZ students or institutes that work with ETHZ know those
systems.

--
Paulo

On Mar 22, 4:10 pm, David Leimbach <leim...@gmail.com> wrote:
> Lazarus/FreePascal has neat stuff like range types.  :-)
>
> And it does NOT have to be a troll at all.  Oberon is a damned fine system
> and a Pascal derivative.
>
> Dave
>
>
>
>
>
>
>
> On Wednesday, March 20, 2013 1:29:36 PM UTC-7, Nate Finch wrote:
>
> > *I mean, really.... this has to be a troll.*

egon

unread,
Mar 23, 2013, 9:37:22 AM3/23/13
to golan...@googlegroups.com, egon

On Friday, March 22, 2013 5:12:17 PM UTC+2, David Leimbach wrote:
 but Javascript just makes me feel ill for some reason.  I even like prototype based languages like Io, but not Javascript!!!  I don't know why!

I started liking javascript after I stopped trying to write class-oriented code (like Java) and started really embracing closures, objects and prototypes. It has a ton of quirks, but there aren't too many of them: http://bonsaiden.github.com/JavaScript-Garden/.

Here's the basic ideas how to write javascript code: https://gist.github.com/egonelbre/5227751 (just some random examples I quickly wrote)
 
Egon

David Leimbach

unread,
Mar 25, 2013, 10:48:14 AM3/25/13
to golan...@googlegroups.com, paulo....@gmail.com


On Saturday, March 23, 2013 3:39:40 AM UTC-7, Paulo Pinto wrote:
Oberon and its sucessors Component Pascal, Oberon-2 and Active Oberon
are
quite interesting languages.

And also show how to write desktop operating systems in GC enabled
system programming
languages with acceptable performance.

Sadly only ETHZ students or institutes that work with ETHZ know those
systems.


Yes, but people can change that for themselves.  I just decided to pick up Pharo 2.0 for fun, and it really truly is a lot of fun.  Being able to debug a program, and edit the code in the debugger, and then restart is a really interesting way to program anything :-).  Also, an image based platform reminds me of how people try to roll out PaaS or any *aaS system these days.  There's a web-enabled version of smalltalk called SeaSide for making websites... makes a lot of sense for some projects.

My point is/was that if you see a new language and want to learn it, a lot of times the best way is to read and change code that's available until you "get it".  You can't wait for a class to be offered at your place of work or your university.  

Once I get the hang of smalltalk/pharo I'm hoping to get into some Oberon based system.  It looks like some old Phillips based controllers I used to program can be targeted with Oberon these days.  It's kind of impressive!


Dave

atomly

unread,
Mar 25, 2013, 2:33:12 PM3/25/13
to golan...@googlegroups.com
On Friday, March 22, 2013 7:17:17 PM UTC-4, John Drummond wrote:
Thanks for the advice guys.  It WAS a serious question. 

For code thats cross platform and reasonably fast it seems to me its Go,  Lazarus, C++, or possibly Python or Java.  I was totally sold on Go but Lazarus is a new one on me and it did seem to just work and has RAD although I'm not really after a GUI.  I really appreciate your views - honestly!  

I would add Scala to that list if I were you.

Personally, the only two languages I would consider seriously for doing cross-platform development on most large-ish projects these days are Scala and Go. Scala is currently much easier for DB dev because it inherits all of Java's DB code...
Reply all
Reply to author
Forward
0 new messages