Version française
Home     About     Download     Resources     Contact us    
Browse thread
When functional languages can be accepted by industry?
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Dennis (Gang) Chen <Dennis.G.Chen@m...>
Subject: Re: When functional languages can be accepted by industry?
> I'm not sure I understand what features of pointers in C you want.  Yes,
> arbitrary pointer arithmetic is not available.  But, when you work with
> mutable data structures in ocaml, the things you assign behave a lot like
> pointers in C or C++.

Thank you very much. Now I find that a mutable linked list can indeed be elegantly
implemented in ocaml, e.g.:

type 'a mlist = Empty | Node of 'a mlist ref * 'a ref;;

This is what I didn't realized before.

Cheers.


--
Dennis Gang CHEN    Senior Software Engineer
Motorola Australia Software Centre, Electronic Design Automation
2 Second Avenue, Mawson Lakes, SA 5095, Australia
phone: +61 8 8203 3560,  mailto: Dennis.G.Chen@motorola.com