From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail4-relais-sop.national.inria.fr (mail4-relais-sop.national.inria.fr [192.134.164.105]) by walapai.inria.fr (8.13.6/8.13.6) with ESMTP id q0KL7PRw023038 for ; Fri, 20 Jan 2012 22:07:25 +0100 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AioBAKnWGU/RVdY0kGdsb2JhbABDrgIIIgEBAQEHCw0HFAQhgXIBAQEEEgITGQEbHQEDDAYFCw0uIgERAQUBHAYTIqM9Cotqgm+EZT+IcQIFC4wbBIg8jF2OED2EHw X-IronPort-AV: E=Sophos;i="4.71,544,1320620400"; d="scan'208";a="128292668" Received: from mail-bk0-f52.google.com ([209.85.214.52]) by mail4-smtp-sop.national.inria.fr with ESMTP/TLS/RC4-SHA; 20 Jan 2012 22:07:22 +0100 Received: by bkar19 with SMTP id r19so1260562bka.39 for ; Fri, 20 Jan 2012 13:07:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; bh=JK7dwjNLVimkL5fQNxzYObTWLyBZm6UVt9AOQ6Bdquw=; b=PeohI/9Ptt02mH0wnk1/799LirllKOvf6+zCBbCvQOBltTCTF6JV2tUV5DCM9QVHfF Lb8vr7dVa26/6lHBGHFtpeTXABw8Wl7+iRz7k4yjWc7UCxDGD1S2lyJsvsqDbFdRuxCE Q4oD7w7KG2a2W/zVEI2lCH493haUAtszalKS8= MIME-Version: 1.0 Received: by 10.204.145.82 with SMTP id c18mr9240489bkv.121.1327093641366; Fri, 20 Jan 2012 13:07:21 -0800 (PST) Received: by 10.204.171.79 with HTTP; Fri, 20 Jan 2012 13:07:21 -0800 (PST) In-Reply-To: <20120120204024.GA2126@siouxsie> References: <20120120204024.GA2126@siouxsie> Date: Fri, 20 Jan 2012 13:07:21 -0800 Message-ID: From: Martin DeMello To: oliver Cc: OCaml List Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by walapai.inria.fr id q0KL7PRw023038 Subject: Re: [Caml-list] is there a more concise way to write this? On Fri, Jan 20, 2012 at 12:40 PM, oliver wrote: > On Thu, Jan 19, 2012 at 10:38:53PM -0800, Martin DeMello wrote: >>       let a = match (out, value) with >>         (true, true)  -> [o; v] >>       | (false, true) -> [v] >>       | (true, false) -> [o] >>       | (false, false) -> [] > [...] > > > Is there a way to get out and value from o and v? No, out and value are just boolean inputs to the function to control how the output is built up out of the individual parts. martin