blob: 9d86a4e1e0e552d0d344e4ff6d7b7f037fa1ccd8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
|
{ Source provided for Free Pascal Bug Report 2536 }
{ Submitted by "Michael Van Canneyt" on 2003-06-14 }
{ e-mail: Michael.VanCanneyt@wisa.be }
unit tw2536;
interface
Type
TWSAData = Pointer;
var
// Delphi accepts this.
WSAStartup: function(wVersionRequired: Word; var WSData: TWSAData): Integer stdcall = nil;
// FPC should accept this too
WSAStartup2: function(wVersionRequired: Word; var WSData: TWSAData): Integer;stdcall = nil;
implementation
end.unit testu2;
interface
Type
TWSAData = Pointer;
const
// FPC and Delphi accepts this.
WSAStartup: function(wVersionRequired: Word; var WSData: TWSAData): Integer stdcall = nil;
// FPC does not accept this.
WSAStartup2: function(wVersionRequired: Word; var WSData: TWSAData): Integer = nil; stdcall;
implementation
end.
unit testu3;
interface
Type
TWSAData = Pointer;
TStartupFunction = function(wVersionRequired: Word; var WSData: TWSAData): Integer stdcall;
TStartupFunction2 = function(wVersionRequired: Word; var WSData: TWSAData): Integer; stdcall;
var
WSAStartup: TStartupFunction = nil;
WSAStartup2: TStartupFunction2 = Nil;
implementation
end.
|