Bug #59
Typing hole when using dot operator
| Status: | New | Start: | 01/29/2009 | |
|---|---|---|---|---|
| Priority: | Normal | Due date: | ||
| Assigned to: | - | % Done: | 0% |
|
| Category: | - | |||
| Target version: | - | |||
| Platform: | All | Triage Stage: | Unreviewed | |
| Resolution: |
Description
There is a serious typing hole that allows for exemple to apply a binary operation to only one argument.
define Int
add(Int a, Int b)
=
a + b.
define Int -> Int
id(Int -> Int f)
=
f.
define $U
$T x .$T -> $U f
=
f(x).
define Int
bad_operation (Int n)
=
n . id (add).
History
Updated by SpiceGuid - almost 3 years ago
Certainly n . id (add) is the same as add(n), isn't it ?
So, why does it compile ?