From ddad57e7a91f47341e3a7c28860c10c5b02fa6ba Mon Sep 17 00:00:00 2001 From: Araq Date: Wed, 8 May 2019 15:05:21 +0200 Subject: [PATCH 1/2] typo --- compiler/extccomp.nim | 2 +- compiler/packagehandling.nim | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/compiler/extccomp.nim b/compiler/extccomp.nim index dfbd2626a6..d7f1d48ade 100644 --- a/compiler/extccomp.nim +++ b/compiler/extccomp.nim @@ -663,7 +663,7 @@ proc compileCFiles(conf: ConfigRef; list: CFileList, script: var Rope, cmds: var if optCompileOnly notin conf.globalOptions: add(cmds, compileCmd) let (_, name, _) = splitFile(it.cname) - add(prettyCmds, if hintCC in conf.notes: "CC: " & demaglePackageName(name) else: "") + add(prettyCmds, if hintCC in conf.notes: "CC: " & demanglePackageName(name) else: "") if optGenScript in conf.globalOptions: add(script, compileCmd) add(script, "\n") diff --git a/compiler/packagehandling.nim b/compiler/packagehandling.nim index 548668824c..b9db61b4dd 100644 --- a/compiler/packagehandling.nim +++ b/compiler/packagehandling.nim @@ -43,7 +43,7 @@ proc fakePackageName*(conf: ConfigRef; path: AbsoluteFile): string = result = relativeTo(path, conf.projectPath, '/').string.multiReplace( {"/": "7", "..": "_", "7": "77", "_": "__", ":": "8", "8": "88"}) -proc demaglePackageName*(path: string): string = +proc demanglePackageName*(path: string): string = result = path.multiReplace( {"88": "8", "8": ":", "77": "7", "__": "_", "_7": "../", "7": "/"}) From f6c9fe789f662342bb44117a1fe98a7a585a8f4d Mon Sep 17 00:00:00 2001 From: Araq Date: Wed, 8 May 2019 16:31:59 +0200 Subject: [PATCH 2/2] fixes #11200 --- compiler/semtypinst.nim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/compiler/semtypinst.nim b/compiler/semtypinst.nim index 18e59681d2..1686cd1f16 100644 --- a/compiler/semtypinst.nim +++ b/compiler/semtypinst.nim @@ -254,7 +254,7 @@ proc replaceTypeVarsS(cl: var TReplTypeVars, s: PSym): PSym = # (e.g. skGenericParam and skType). # Note: `s.magic` may be `mType` in an example such as: # proc foo[T](a: T, b = myDefault(type(a))) - if s.kind in routineKinds or s.magic != mNone: + if s.kind in routineKinds+{skLet, skConst, skVar} or s.magic != mNone: return s #result = PSym(idTableGet(cl.symMap, s))