On Thu, 03 Feb 2011 12:45:33 +0100 dexen deVries <dexen.devr...@gmail.com>  
wrote:
> 
> why do we keep distinction between files and directories?

David Cheriton's `thoth' operating system didn't keep this
distinction. But every other OS I know of keeps them
separate.  IIRC thoth provided functions for getting the
first child or next sibing given a path name. [Cheriton used
words like father, son, brother -- this was pre-PC!]

> Does it provide any extra value over model with unified file/directory?
 
They serve functions. A directory is an associative table,
indexed by a string key. A file is an array, indexed by an
integer. But most filesystems do store some attributes with a
file thus breaking this simple model.

One advantage of always storing a directory with a file is
that you can represent file attributes via a directory.  Then
you can have an extensible attributes model.  XML probably
maps well to this model.

Not sure doing so in plan9 makes any sense but you could
build an experimental OS around it! But if you go this path,
do consider providing a few more datatypes in the filesystem
(integers, file-id, strings, ...).  Basically persistent data
types. Or just use an object or relational database as your
filesystem.

There are some uses for cloud based strings :-)

Reply via email to