* fixes #3748

* fix the regression

* don't use the new allocator for the SSL wrapper

* fixes regression
This commit is contained in:
Andreas Rumpf 2022-10-14 12:00:38 +02:00 • committed by GitHub
commit 07b645342a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 24 additions and 6 deletions

View file

@ -69,7 +69,7 @@ type
efWantStmt, efAllowStmt, efDetermineType, efExplain,
efWantValue, efOperand, efNoSemCheck,
efNoEvaluateGeneric, efInCall, efFromHlo, efNoSem2Check,
efNoUndeclared
efNoUndeclared, efIsDotCall
# Use this if undeclared identifiers should not raise an error during
# overload resolution.

View file

@ -973,7 +973,7 @@ proc semIndirectOp(c: PContext, n: PNode, flags: TExprFlags; expectedType: PType
var prc = n[0]
if n[0].kind == nkDotExpr:
checkSonsLen(n[0], 2, c.config)
let n0 = semFieldAccess(c, n[0])
let n0 = semFieldAccess(c, n[0], {efIsDotCall})
if n0.kind == nkDotCall:
# it is a static call!
result = n0
@ -1474,8 +1474,9 @@ proc dotTransformation(c: PContext, n: PNode): PNode =
proc semFieldAccess(c: PContext, n: PNode, flags: TExprFlags): PNode =
# this is difficult, because the '.' is used in many different contexts
# in Nim. We first allow types in the semantic checking.
result = builtinFieldAccess(c, n, flags)
if result == nil:
result = builtinFieldAccess(c, n, flags - {efIsDotCall})
if result == nil or ((result.typ == nil or result.typ.skipTypes(abstractInst).kind != tyProc) and
efIsDotCall in flags and callOperator notin c.features):
result = dotTransformation(c, n)
proc buildOverloadedSubscripts(n: PNode, ident: PIdent): PNode =