This commit is contained in:
Andreas Rumpf
2018-01-30 19:51:38 +01:00
parent 77d590f483
commit a605fa8ba6
4 changed files with 5 additions and 5 deletions

View File

@@ -908,7 +908,6 @@ proc addIntTypes(result: var Rope) {.inline.} =
platform.CPU[targetCPU].intSize.rope])
proc getCopyright(cfile: Cfile): Rope =
const copyrightYear = "2017"
if optCompileOnly in gGlobalOptions:
result = ("/* Generated by Nim Compiler v$1 */$N" &
"/* (c) " & copyrightYear & " Andreas Rumpf */$N" &

View File

@@ -54,7 +54,7 @@ proc processSwitch*(switch, arg: string, pass: TCmdLinePass, info: TLineInfo;
const
HelpMessage = "Nim Compiler Version $1 [$2: $3]\n" &
"Copyright (c) 2006-2017 by Andreas Rumpf\n"
"Copyright (c) 2006-" & copyrightYear & " by Andreas Rumpf\n"
const
Usage = slurp"../doc/basicopt.txt".replace("//", "")

View File

@@ -2390,7 +2390,7 @@ proc genHeader(target: TTarget): Rope =
if target == targetJS:
result = (
"/* Generated by the Nim Compiler v$1 */$n" &
"/* (c) 2017 Andreas Rumpf */$n$n" &
"/* (c) " & copyrightYear & " Andreas Rumpf */$n$n" &
"var framePtr = null;$n" &
"var excHandler = 0;$n" &
"var lastJSError = null;$n" &
@@ -2406,7 +2406,7 @@ proc genHeader(target: TTarget): Rope =
else:
result = ("<?php$n" &
"/* Generated by the Nim Compiler v$1 */$n" &
"/* (c) 2017 Andreas Rumpf */$n$n" &
"/* (c) " & copyrightYear & " Andreas Rumpf */$n$n" &
"$$framePtr = null;$n" &
"$$excHandler = 0;$n" &
"$$lastJSError = null;$n") %
@@ -2464,7 +2464,7 @@ proc genClass(obj: PType; content: Rope; ext: string) =
else: nil
let result = ("<?php$n" &
"/* Generated by the Nim Compiler v$# */$n" &
"/* (c) 2017 Andreas Rumpf */$n$n" &
"/* (c) " & copyrightYear & " Andreas Rumpf */$n$n" &
"require_once \"nimsystem.php\";$n" &
"class $#$# {$n$#$n}$n") %
[rope(VersionAsString), cls, extends, content]

View File

@@ -18,6 +18,7 @@ const
newScopeForIf* = true
useCaas* = not defined(noCaas)
noTimeMachine* = defined(avoidTimeMachine) and defined(macosx)
copyrightYear* = "2018"
type # please make sure we have under 32 options
# (improves code efficiency a lot!)