[erlang-questions] inet.erl socket_setopt type incomplete
Loïc Hoguin
essen@REDACTED
Tue Jul 12 18:27:21 CEST 2011
This probably should be in erlang-bugs@ instead. I confirm having seen
this issue before too.
On 07/07/2011 08:43 PM, James Aimonetti wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> In R14B03, the type socket_setopt() in inet.erl does not allow for the
> convenience options 'binary' and 'list' (which internally get translated
> to {'mode', 'binary' | 'list'} which *is* in the type), and this causes
> Dialyzer to complain about inet:setopts(Socket, [{active, once},
> binary]) (in my case).
>
> Setting the options list to [{active, once}, {mode, binary}] alleviates
> the Dialyzer warning but doesn't reflect what the function actually allows.
>
> - --
> James Aimonetti
> Distributed Systems Engineer / DJ MC_
>
> 2600hz | http://2600hz.com
> sip:james@REDACTED
> tel: 415.886.7905
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.10 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
>
> iQEcBAEBAgAGBQJOFf5kAAoJENc77s1OYoGgCAsH/3avCJlBdnJ0c78naoclMWre
> +AC9amjmTrVCkp6dg5mkCnMFsGpImCba171qMx3005pVS/e123px+6ek86cda9Gy
> rhIusElV8TR6r08QNzcbcdEHW89vbzYN6Gmc0AhnJX1gS6yBQ6vhn9tH3HxgaroZ
> N3VZCUAuyKaun2sWii7WfI0LdtxmWBxsZmUnpywPZhNOFm9A0hyY1rH533y+KIKJ
> kfleH3iO2E4tasE9U8eRNX2E9+fM00sXlVE84RUxVAonMcRTZyqBFxBa3nRStgii
> ShClwNH3CXnRiCgUgZhu6bW7Zd1Umq7Ru3gRRxcJTrTMJ2T8MfsD8EQ8/rgtVhw=
> =qgkH
> -----END PGP SIGNATURE-----
> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://erlang.org/mailman/listinfo/erlang-questions
--
Loïc Hoguin
Dev:Extend
More information about the erlang-questions
mailing list