Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Warning for unused record fields #10232

Merged
merged 4 commits into from
Mar 30, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 3 additions & 0 deletions Changes
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,9 @@ Working version
It is now deprecated to improve the coexistence with warning mnemonics.
(Florian Angeletti, review by Damien Doligez and Gabriel Scherer)

- #10232: Warning for unused record fields.
(Leo White, review by Florian Angeletti)

### Internal/compiler-libs changes:

- #9243, simplify parser rules for array indexing operations
Expand Down
5 changes: 2 additions & 3 deletions asmcomp/asmgen.ml
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,6 @@ let end_gen_implementation ?toplevel ~ppf_dump

type middle_end =
backend:(module Backend_intf.S)
-> filename:string
-> prefixname:string
-> ppf_dump:Format.formatter
-> Lambda.program
Expand All @@ -235,15 +234,15 @@ let asm_filename output_prefix =
then output_prefix ^ ext_asm
else Filename.temp_file "camlasm" ext_asm

let compile_implementation ?toplevel ~backend ~filename ~prefixname ~middle_end
let compile_implementation ?toplevel ~backend ~prefixname ~middle_end
~ppf_dump (program : Lambda.program) =
compile_unit ~output_prefix:prefixname
~asm_filename:(asm_filename prefixname) ~keep_asm:!keep_asm_file
~obj_filename:(prefixname ^ ext_obj)
(fun () ->
Ident.Set.iter Compilenv.require_global program.required_globals;
let clambda_with_constants =
middle_end ~backend ~filename ~prefixname ~ppf_dump program
middle_end ~backend ~prefixname ~ppf_dump program
in
end_gen_implementation ?toplevel ~ppf_dump clambda_with_constants)

Expand Down
2 changes: 0 additions & 2 deletions asmcomp/asmgen.mli
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
(** The type of converters from Lambda to Clambda. *)
type middle_end =
backend:(module Backend_intf.S)
-> filename:string
-> prefixname:string
-> ppf_dump:Format.formatter
-> Lambda.program
Expand All @@ -28,7 +27,6 @@ type middle_end =
val compile_implementation
: ?toplevel:(string -> bool)
-> backend:(module Backend_intf.S)
-> filename:string
-> prefixname:string
-> middle_end:middle_end
-> ppf_dump:Format.formatter
Expand Down
1 change: 0 additions & 1 deletion asmcomp/asmpackager.ml
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,6 @@ let make_package_object ~ppf_dump members targetobj targetname coercion
program, Closure_middle_end.lambda_to_clambda
in
Asmgen.compile_implementation ~backend
~filename:targetname
~prefixname
~middle_end
~ppf_dump
Expand Down