English version
Accueil     À propos     Téléchargement     Ressources     Contactez-nous    

Ce site est rarement mis à jour. Pour les informations les plus récentes, rendez-vous sur le nouveau site OCaml à l'adresse ocaml.org.

Browse thread
[Caml-list] unix.chop_extension
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2004-05-26 (09:34)
From: Luca Pascali <pasckosky2000@y...>
Subject: Re: [Caml-list] unix.chop_extension
Xavier Leroy wrote:


>>here's one extra thing I'd like to point out. We have the 
>>chop_extension function. Why in the world is there no find_extension 
>>find_extension "foo.bar" --> "bar"
>Why in the world would that be generally useful?  Remember, we don't
>shoot for completeness (it's unattainable anyway), just for
>- Xavier Leroy
IMHO, this might be considered more as a matter of usefulness instead of 

I mean that there are systems (like Windows) that use only the extension 
of the file to identify how to execute or how to read the file itself, 
and anyway the extension is useful to classify a file for any kind of 
application (such as compilers, network applications, graphic editing, 
and so on).
So a developer has to write its own function to extract the extension 
from a filename every time he/she needs. Its not a big deal, but ...

My opinion.


To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners