tnicerrorforsymchoice.nim 778 B

123456789101112131415161718192021222324
  1. discard """
  2. errormsg: "type mismatch: got <proc (s: TScgi: ScgiState or AsyncScgiState) | proc (client: AsyncSocket, headers: StringTableRef, input: string){.noSideEffect, gcsafe, locks: 0.}>"
  3. line: 23
  4. """
  5. # Fake ScgiState objects, from now-deprecated scgi module
  6. type
  7. ScgiState* = object of RootObj ## SCGI state object
  8. AsyncScgiState* = object of RootObj ## SCGI state object
  9. #bug #442
  10. import asyncnet, strtabs
  11. proc handleSCGIRequest[TScgi: ScgiState | AsyncScgiState](s: TScgi) =
  12. discard
  13. proc handleSCGIRequest(client: AsyncSocket, headers: StringTableRef,
  14. input: string) =
  15. discard
  16. proc test(handle: proc (client: AsyncSocket, headers: StringTableRef,
  17. input: string), b: int) =
  18. discard
  19. test(handleSCGIRequest)