From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@sympa.inria.fr Delivered-To: caml-list@sympa.inria.fr Received: from mail3-relais-sop.national.inria.fr (mail3-relais-sop.national.inria.fr [192.134.164.104]) by sympa.inria.fr (Postfix) with ESMTPS id 59F4E80143 for ; Tue, 30 May 2017 00:18:37 +0200 (CEST) Authentication-Results: mail3-smtp-sop.national.inria.fr; spf=None smtp.pra=nicolas.ojeda.bar@lexifi.com; spf=None smtp.mailfrom=nicolas.ojeda.bar@lexifi.com; spf=None smtp.helo=postmaster@vrout30.yaziba.net Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of nicolas.ojeda.bar@lexifi.com) identity=pra; client-ip=185.56.204.35; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="nicolas.ojeda.bar@lexifi.com"; x-sender="nicolas.ojeda.bar@lexifi.com"; x-conformance=sidf_compatible Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of nicolas.ojeda.bar@lexifi.com) identity=mailfrom; client-ip=185.56.204.35; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="nicolas.ojeda.bar@lexifi.com"; x-sender="nicolas.ojeda.bar@lexifi.com"; x-conformance=sidf_compatible Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of postmaster@vrout30.yaziba.net) identity=helo; client-ip=185.56.204.35; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="nicolas.ojeda.bar@lexifi.com"; x-sender="postmaster@vrout30.yaziba.net"; x-conformance=sidf_compatible IronPort-PHdr: =?us-ascii?q?9a23=3AwD2qQhIiYcCQu1Es0dmcpTZWNBhigK39O0sv0rFi?= =?us-ascii?q?tYgfI/rxwZ3uMQTl6Ol3ixeRBMOAuqwC1rWe8/i5HzdRvtDZ6DFKWacPfiFGoP?= =?us-ascii?q?1VpTBoONSCB0z/IayiRA0BN+MGamVY+WqmO1NeAsf0ag6aiHSz6TkPBke3blIt?= =?us-ascii?q?daz6FYHIksu4yf259YHNbAVUnjq9Zq55IAmroQnLuMQbhYpvJrwxxxbLv3BEf/?= =?us-ascii?q?hayX5yKV+dmxvx5N288IJ//yhVpvks69NOXaLmcqs3SrBVEC4oP2cp6sP1qBLN?= =?us-ascii?q?VxGP5nwSUmUXlhpHHQ3I5wzkU5nyryX3qPNz1DGVMsPqQ780Xy+i77pwRx/zlC?= =?us-ascii?q?gHLT85/3rJhcF2kalWvQiupx17w47TfYGVKP9zdb7TcN8GWWZMWNtaWjdfCY2g?= =?us-ascii?q?cYQAE+sBPf5Zr4bjoVsOsQC+DhSoCO/21zNEmmP60ag83usmDA/GwRcgH8oQv3?= =?us-ascii?q?vIsNX7OqASUeWvw6nJyzXIcvda1Dj55YTNdB0qvPOCUq9qccfJy0YvGQPLgFuT?= =?us-ascii?q?p4L4IT2ayv8AvHKH4+d6T++jl3IrpgN3rzOyxskskI7JhocNx17c9CV23IE1Jd?= =?us-ascii?q?m6T05gedGqCZlQuD+HOIRsWswvXmRvuDwnwbABv567fTQFyJMjxxHFcPyLaY+I?= =?us-ascii?q?4hD9W+mMOzh0nmlqd6ilhxup9Uiv1OL9Vsi60FZLtCZKjt7MtnUU2hHV98OJRP?= =?us-ascii?q?x9/kK71jaO0QDe8uBEIUYularaMZEt2LAwloALvUXDBCD2mEL2jKiMeko4/eio?= =?us-ascii?q?7uLqaajlqJ+EL4J4lwLzP6Q0lsG/AOk0KBYCU3SU9Oim2rDu/VX1TKtWgvAyiK?= =?us-ascii?q?XUs5DXKd4FqqKnHwNZyJsv5hWhAzqgzd8Wh2MILEhfdxKCl4XpO0/BIPT/Dfqn?= =?us-ascii?q?nVSsijBrx+3aPrDvHpnBNHjCn63gfLZ88EFT0hA/zdZB6JJIEr0BIfTzVVHttN?= =?us-ascii?q?HAExM0MAy5z/znBdh8zI8SR36DD6CDPK7csVKE/ucvLPONZI8Rtjb9Mf8l5/v2?= =?us-ascii?q?gH8/mF8SYa6p3Z8NZ3CjBPhmJEeZbmTxjdgbC2sFpRAxTPbxhV2GTzFSaHeyX6?= =?us-ascii?q?w95j0hFI2mCoLDSpi3gLOdxCe7AoFWZmdeB1+QC3jocoGEV+4IaCKTOc9hjicJ?= =?us-ascii?q?VaOhSo8kzRGhrhX2y7thLurO+y0Xr4jv1NZv5+HLkBEy8iF7ANqF3mGWSmF0gn?= =?us-ascii?q?sIRzgr3KBj8gRBzQKh1rN4y9ZVD9BS4f4BBgU9Lp70xeFgB9H0V0THc8vfG3i8?= =?us-ascii?q?RdDzJzA6Sda42OgpYUtxEuKIAgqLiyyrCLgRnqfNA545/qua1XHrD8Jw23fI1e?= =?us-ascii?q?8qiFxwEZgHDnGvmqMqr1ubPIXOiUjM0vvzeA=3D=3D?= X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: =?us-ascii?q?A0ABAQAinSxZhiPMOLldHAEBBAEBCgEBF?= =?us-ascii?q?wEBBAEBCgEBhAyBDQeDa4E2iGJzkHMQgi+TOoIPLIV4AoJSRhgBAQEBAQEBAQE?= =?us-ascii?q?BARIBAQEKCQsIKC+CMySCQgECAgEjBEcLBQsLBAcaHQICIhIBBQEKEgYTCAqKA?= =?us-ascii?q?AMNCAQBC58rP4wHgWw6hycDhBsBAQEBBgEBAQEBASKLYId7gmABBIdpDJYuhyC?= =?us-ascii?q?MCIJbjxyTBhQfgRMCDxCBQnRbGQaEK0mBcXSJeQEBAQ?= X-IPAS-Result: =?us-ascii?q?A0ABAQAinSxZhiPMOLldHAEBBAEBCgEBFwEBBAEBCgEBhAy?= =?us-ascii?q?BDQeDa4E2iGJzkHMQgi+TOoIPLIV4AoJSRhgBAQEBAQEBAQEBARIBAQEKCQsIK?= =?us-ascii?q?C+CMySCQgECAgEjBEcLBQsLBAcaHQICIhIBBQEKEgYTCAqKAAMNCAQBC58rP4w?= =?us-ascii?q?HgWw6hycDhBsBAQEBBgEBAQEBASKLYId7gmABBIdpDJYuhyCMCIJbjxyTBhQfg?= =?us-ascii?q?RMCDxCBQnRbGQaEK0mBcXSJeQEBAQ?= X-IronPort-AV: E=Sophos;i="5.38,415,1491256800"; d="scan'208,217";a="226670364" Received: from vrout30-bl.yaziba.net (HELO vrout30.yaziba.net) ([185.56.204.35]) by mail3-smtp-sop.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-SHA; 30 May 2017 00:18:36 +0200 Received: from mtaout20.int.yaziba.net (mtaout20.int.yaziba.net [10.4.20.37]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by vrout30.yaziba.net (mx10.yaziba.net) with ESMTPS id 87E2D5211B for ; Tue, 30 May 2017 00:18:35 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by mtaout20.int.yaziba.net (Postfix) with ESMTP id 4376116036F for ; Tue, 30 May 2017 00:18:38 +0200 (CEST) X-Virus-Scanned: amavisd-new at mtaout20.int.yaziba.net Received: from mtaout20.int.yaziba.net ([127.0.0.1]) by localhost (mtaout20.int.yaziba.net [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id J_7rsSC3AXrW for ; Tue, 30 May 2017 00:18:38 +0200 (CEST) Received: from mail-qk0-f182.google.com (mail-qk0-f182.google.com [209.85.220.182]) by mtaout20.int.yaziba.net (Postfix) with ESMTPSA id EFC331602C4 for ; Tue, 30 May 2017 00:18:37 +0200 (CEST) Received: by mail-qk0-f182.google.com with SMTP id y201so56410403qka.0 for ; Mon, 29 May 2017 15:18:35 -0700 (PDT) X-Gm-Message-State: AODbwcDrOjwBPUyHoQ6mFjFICSjfM9caRW4Q74jqfTnZi7ySUpPTIfIp oXISJiCDpM2Jsp5Kej5H+4G4JRG9Aw== X-Received: by 10.55.70.69 with SMTP id t66mr19621716qka.147.1496096314141; Mon, 29 May 2017 15:18:34 -0700 (PDT) MIME-Version: 1.0 Received: by 10.200.34.130 with HTTP; Mon, 29 May 2017 15:18:13 -0700 (PDT) In-Reply-To: References: From: =?UTF-8?Q?Nicol=C3=A1s_Ojeda_B=C3=A4r?= Date: Tue, 30 May 2017 00:18:13 +0200 X-Gmail-Original-Message-ID: Message-ID: To: Josh Berdine Cc: OCaml Mailing List Content-Type: multipart/alternative; boundary="001a114abc525ab0740550b111c7" X-DRWEB-SCAN: ok X-VRSPAM-SCORE: -51 X-VRSPAM-STATE: legit X-VRSPAM-CAUSE: gggruggvucftvghtrhhoucdtuddrfeeljedrgeefgddugecutefuodetggdotefrucfrrhhofhhilhgvmecuggftfghnshhusghstghrihgsvgenuceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnegoufhushhpvggtthffohhmrghinhculdegledmnecujfgurhepjghfhfffkffuvfgtsegrtderredttdejnecuhfhrohhmpefpihgtohhljohspgfqjhgvuggrpgeumohruceonhhitgholhgrshdrohhjvggurgdrsggrrheslhgvgihifhhirdgtohhmqeenucffohhmrghinhepihhnrhhirgdrfhhrpdihrghhohhordgtohhmnecukfhppedvtdelrdekhedrvddvtddrudekvdenucfrrghrrghmpehmohguvgepshhmthhpohhuth X-VRSPAM-EXTCAUSE: mhhouggvpehsmhhtphhouhht Subject: Re: [Caml-list] enabling warnings using compiler-libs --001a114abc525ab0740550b111c7 Content-Type: text/plain; charset="UTF-8" Hi Josh, I think you can use Warnings.parse_options : bool -> string -> unit for that. The first flag indicates if the warning should be an error and the second argument specifies the warnings in the usual format. For example, Warnings.parse_options true "+50" would activate Warning 50 as an error, etc. Best wishes, Nicolas On Mon, May 29, 2017 at 11:59 PM, Josh Berdine wrote: > I would like to call e.g. Parse.implementation from compiler-libs with > warning 50 'Bad_docstring' enabled. Have I overlooked something, or is > that not possible using the standard exposed interface? > > I guess that one warning that involves the parser might not justify the > overhead of adding an interface? > > Cheers, Josh > > -- > Caml-list mailing list. Subscription management and archives: > https://sympa.inria.fr/sympa/arc/caml-list > Beginner's list: http://groups.yahoo.com/group/ocaml_beginners > Bug reports: http://caml.inria.fr/bin/caml-bugs > --001a114abc525ab0740550b111c7 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi Josh,

I think you can use
=
=C2=A0 Warnings.parse_options : bool -> string -> unit=

for that.=C2=A0 The first flag indicates if the w= arning should be an error and the second argument specifies the warnings in= the usual format.=C2=A0 For example,=C2=A0

=C2=A0= Warnings.parse_options true "+50"

would= activate Warning 50 as an error, etc.

Best wishes= ,
Nicolas

On Mon, May 29, 2017 at 11:59 PM, Josh Berdine= <josh@berdine.net> wrote:
= I would like to call e.g. Parse.implementation from compiler-libs with warn= ing 50 'Bad_docstring' enabled.=C2=A0 Have I overlooked something, = or is that not possible using the standard exposed interface?

I guess that one warning that involves the parser might not justify the ove= rhead of adding an interface?

Cheers, Josh

--
Caml-list mailing list.=C2=A0 Subscription management and archives:
https://sympa.inria.fr/sympa/arc/caml-list
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
Bug reports: http://caml.inria.fr/bin/caml-bugs

--001a114abc525ab0740550b111c7--