I would like to declare an infix operator within a structure a for use outside the structure. But I cannot seem to get the "infixness" to be recognized outside the structure even when the structure has been opened. Here is an example using Poly/ML:
> structure A = struct infix 6 ++ fun a ++ b = a + b end;
structure A: sig val ++: int * int -> int end
> 1 A.++ 2;
poly: : error: Type error in function application.
Function: 1 : int
Argument: A.++ : int * int -> int
Reason: Value being applied does not have a function type
Found near 1 A.++ 2
Static Errors
> let open A in 1 ++ 2 end;
poly: : error: Type error in function application.
Function: 1 : int
Argument: ++ : int * int -> int
Reason: Value being applied does not have a function type
Found near let open A in 1 ++ 2 end
Static Errors
Is this a limitation of Standard ML?