Removed "proc ==(a: syserr, b: err_t)" and three other comparisons involving err_t in modules/standard/SysBasic.chpl.
Removed "proc ==(a: syserr, b: err_t)" and three other comparisons involving err_t in modules/standard/SysBasic.chpl.

[Reviewed/discussed with Brad and Michael.]

I am removing the following comparisons:

  inline proc ==(a: syserr, b: err_t)
  inline proc ==(a: err_t, b: syserr)
  inline proc !=(a: syserr, b: err_t)
  inline proc !=(a: err_t, b: syserr)

Explanation: Consider, for example, the first of the above.
SysBasic.chpl defined, since r21066:

  inline proc ==(a: syserr, b: err_t)
  inline proc ==(a: syserr, b: int(32))
  inline proc ==(a: syserr, b: int(64))

Since err_t is int(32), the first two functions always will be ambiguous
whenever one of them applies. I don't know why we have not hit this
ambiguity in our current code base, but it can get exposed.

Michael would like to make err_t distinct from int(32),
at which point this patch will need to be reverted.

Alternatively to removing, we could guard each function with
  where !_isIntegralType(err_t)
but that would make the current code less elegant.

Michael explains err_t:

  syserr is a pointer-based structure possiblycontaining an error code.
In order for it to be useful, one needs to be able to compare against
the system error codes like ENOENT or EINVAL. These should be wrapped in
the compiler as err_t values.

  I would rather solve the problem by having err_t be a different type
(with the same representation) that can compare against int(32); that
is, right now we have

 extern type err_t = c_int;

which makes err_t another name for c_int, but what I actually want is
for err_t to be a different type that has the same representation, and
to explicitly set which methods allow the combination of err_t and c_int
(as with == ).

  Of course, one way to do that would be to make err_t an opaque type...
but a more general way would be to support the generation of a new type
in these situations (e.g. new type err_t = c_int). 


git-svn-id: 88467cb1fb04b8a755be7e1ee1026be4190196ef@22472 3a8e244f-b0f2-452b-bcba-4c88e055c3ca

hildeth/chapel,chizarlicious/chapel,CoryMcCartan/chapel,chizarlicious/chapel,hildeth/chapel,CoryMcCartan/chapel,hildeth/chapel,sungeunchoi/chapel,sungeunchoi/chapel,hildeth/chapel,chizarlicious/chapel,chizarlicious/chapel,chizarlicious/chapel,sungeunchoi/chapel,CoryMcCartan/chapel,hildeth/chapel,hildeth/chapel,chizarlicious/chapel,sungeunchoi/chapel,CoryMcCartan/chapel,sungeunchoi/chapel,sungeunchoi/chapel,CoryMcCartan/chapel,chizarlicious/chapel,CoryMcCartan/chapel,sungeunchoi/chapel,CoryMcCartan/chapel,sungeunchoi/chapel,hildeth/chapel