File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change 99 | Directory of {fs_map : filesys Map_names .t }
1010 | File
1111
12+ let empty_dir = Directory {fs_map = Map_names. empty}
13+
1214 let rec find_opt fs path =
1315 match fs with
1416 | File ->
@@ -183,7 +185,7 @@ struct
183185
184186 let sandbox_root = " _sandbox"
185187
186- let init_state = Directory {fs_map = Map_names. empty}
188+ let init_state = Model. empty_dir
187189
188190 let path_is_a_dir fs path =
189191 match Model. find_opt fs path with
@@ -217,7 +219,7 @@ struct
217219 | Mkdir (path , new_dir_name ) ->
218220 if Model. mem fs (path @ [new_dir_name])
219221 then fs
220- else Model. insert fs path new_dir_name ( Directory {fs_map = Map_names. empty})
222+ else Model. insert fs path new_dir_name Model. empty_dir
221223 | Remove (path , file_name ) ->
222224 if Model. find_opt fs (path @ [file_name]) = Some File
223225 then Model. remove fs path file_name
You can’t perform that action at this time.
0 commit comments