sequoia icon indicating copy to clipboard operation
sequoia copied to clipboard

Upgrade to dune

Open baransu opened this issue 5 years ago • 4 comments

Following PR makes the following changes:

  • updated to dune via dune upgrade
  • fixes many now default dune errors like unused variables, unused opens

Not sure if everything is correct. It was trial and error to get it working with new Reason + esy project.

baransu avatar Oct 23 '19 22:10 baransu

Hi

Thanks for the update, and sorry for the delay. Could you please do as @sagotch mentioned and use the hour parameter in the function instead of removing it? Also, there are some warnings about unused functions like to_string which are actually part of the interface; I believe the warning happens because there is no mli file.

You can try adding those, but it'll be a lot of work. For now I think we could instruct dune to ignore those warnings.

After those changes I can merge the PR.

andrenth avatar Nov 12 '19 13:11 andrenth

Also, there are some warnings about unused functions like to_string which are actually part of the interface; I believe the warning happens because there is no mli file.

  (* let to_string : type a b. (a, b) t -> string = function
    | Time (name, table) -> sprintf "%s.%s" (Table.name table) name
    | Timestamp (name, table) -> sprintf "%s.%s" (Table.name table) name
    | Date (name, table) -> sprintf "%s.%s" (Table.name table) name
    | Datetime (name, table) -> sprintf "%s.%s" (Table.name table) name
    | Enum (name, table, _) -> sprintf "%s.%s" (Table.name table) name
    | Null.Time (name, table) -> sprintf "%s.%s" (Table.name table) name
    | Null.Timestamp (name, table) -> sprintf "%s.%s" (Table.name table) name
    | Null.Date (name, table) -> sprintf "%s.%s" (Table.name table) name
    | Null.Datetime (name, table) -> sprintf "%s.%s" (Table.name table) name
    | Null.Enum (name, table, _) -> sprintf "%s.%s" (Table.name table) name
    | other -> to_string other *)

  let to_string fld =
    let t = table fld in
    sprintf "%s.%s" (Table.name t) (name fld)

to_string is (re)define and the first definition is actually unused.

sagotch avatar Nov 12 '19 14:11 sagotch

Were there any updates on this PR? Would be nice to get this merged.

XVilka avatar Jan 09 '20 05:01 XVilka

Unfortunately not. I was experimenting with this library and trying to make it work for me so I created this PR. I'm not sure I'll have time to finish this.

baransu avatar Jan 09 '20 09:01 baransu