diff options
Diffstat (limited to 'tests/lookups/tnicerrorforsymchoice.nim')
-rw-r--r-- | tests/lookups/tnicerrorforsymchoice.nim | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/lookups/tnicerrorforsymchoice.nim b/tests/lookups/tnicerrorforsymchoice.nim new file mode 100644 index 000000000..6001b6b09 --- /dev/null +++ b/tests/lookups/tnicerrorforsymchoice.nim @@ -0,0 +1,23 @@ +discard """ + errormsg: "type mismatch: got <proc (s: TScgi: ScgiState or AsyncScgiState) | proc (client: AsyncSocket, headers: StringTableRef, input: string){.noSideEffect, gcsafe.}>" + line: 23 +""" + +# Fake ScgiState objects, from now-deprecated scgi module +type + ScgiState* = object of RootObj ## SCGI state object + AsyncScgiState* = object of RootObj ## SCGI state object + +#bug #442 +import asyncnet, strtabs +proc handleSCGIRequest[TScgi: ScgiState | AsyncScgiState](s: TScgi) = + discard +proc handleSCGIRequest(client: AsyncSocket, headers: StringTableRef, + input: string) = + discard + +proc test(handle: proc (client: AsyncSocket, headers: StringTableRef, + input: string), b: int) = + discard + +test(handleSCGIRequest) |